input: Write a function to populate an array with random numbers from 1 to 100. The function should take an integer as input which indicates the length of the array and return the populated array.
  assert populateArray(0)==[]
  assert len(populateArray(5))==5
  assert all(1 <= num <= 100 for num in populateArray(100))
output: import random
  
  def populateArray(n):
      return [random.randint(1, 100) for _ in range(n)]