input: Write a function to generate a random password given a set of letters, numbers, and characters. The function should return the generated password as a string.
  
  
  import random
  
  def generate_password():
      string = "abcdefghijklmnopqrstuvwxyz01234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ!@#$%^&*()?"
      password = "".join(random.sample(string, 8))
      return password
  
  assert len(generate_password()) == 8
  assert any(c.isdigit() for c in generate_password())
  assert any(c.isalpha() for c in generate_password())
  assert any(c in "!@#$%^&*()?" for c in generate_password())
  
output: def generate_password():
      string = "abcdefghijklmnopqrstuvwxyz01234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ!@#$%^&*()?"
      password = "".join(random.sample(string, 8))
      return password