input: Write a function to generate a random password using a combination of letters, digits, and punctuation.
  assert len(generate_password(10))==10
  assert len(generate_password(15))==15
  assert len(generate_password(20))==20
output: import random
  import string
  
  def generate_password(length):
      characters = string.ascii_letters + string.digits + string.punctuation
      password = ''.join(random.choice(characters) for _ in range(length))
      return password