input: Write a function to calculate the number of permutations for a given number.
  assert countPermutations(4) == 24
  assert countPermutations(5) == 120
  assert countPermutations(6) == 720
output: def countPermutations(n):
      if n == 0:
          return 1
      else:
          return n * countPermutations(n - 1)