input: 
  def encrypt(message: str, key: str) -> str:
      """ Encrypts a message using a key by shifting each character in the message by the ASCII value of the first character of the key.
      >>> encrypt("Hello world!", "secret")
      'Tqzz{.u$fqj!'
      """
  
output:     
      encrypted_message = ""
      shift = ord(key[0])
      for char in message:
          if char.isalpha():
              if char.islower():
                  encrypted_message += chr((ord(char) - ord('a') + shift) % 26 + ord('a'))
              else:
                  encrypted_message += chr((ord(char) - ord('A') + shift) % 26 + ord('A'))
          else:
              encrypted_message += char
      return encrypted_message
  