input: Write a function to generate a random password consisting of 8 characters (numbers, letters, and special characters). If no input is provided, the function should generate and print the password. 
  assert generate_password()==True
  assert generate_password()==True
  assert generate_password()==True
  assert generate_password()==True
  assert generate_password()==True
output: import random
  import string
  
  def generate_password():
      characters = string.ascii_letters + string.digits + string.punctuation
      password = ''.join(random.choice(characters) for i in range(8))
      print(password)
      return True