input: Write a function to encrypt a message using a Caesar cipher. The function should take in the message and a shift value, and return the encrypted message. The Caesar cipher shifts each character in the message by the shift value, wrapping around the ASCII character set if necessary.
  assert caesar_encrypt("Hello, World!", 5)=='Mjqqt,%]twqi"'
  assert caesar_encrypt("Python", 10)=='Zidwyx'
  assert caesar_encrypt("Programming", 20)=='Jlobalafqba'
  assert caesar_encrypt("Cryptography", 3)=='Fu{{uyrjudsb'
  assert caesar_encrypt("", 7)=='
output: def caesar_encrypt(message, shift):
      encrypted_message = ""
      for char in message:
          if char.isalpha():
              shift_amount = shift % 26
              if char.islower():
                  new_char = chr((ord(char) - ord('a') + shift_amount) % 26 + ord('a'))
              else:
                  new_char = chr((ord(char) - ord('A') + shift_amount) % 26 + ord('A'))
              encrypted_message += new_char
          else:
              encrypted_message += char
      return encrypted_message