fn vectorize[T](op fn (T) T) fn ([]T) []T {
	return fn [op] [T](values T) []T {
		mut result := []T{}
		return result
	}
}

fn add_one(x f64) f64 {
	return x + 1
}

fn main() {
	vadd := vectorize[f64](add_one)
	v := [1.0, 2, 3, 4]
	println(vadd(v))
}
