Playground

def f (v, x):
  n = len(v)
  if n == 0:
     return 1
  return x*f(v[0:n/2], x-1)