input: Write a function to calculate the cube of a given integer. The function should take an integer input and return the cube of that integer.
  assert cube(2) == 8
  assert cube(3) == 27
  assert cube(0) == 0
  assert cube(-1) == -1
  assert cube(-2) == -8
output: def cube(n):
      return n ** 3