input: Write a function to extract all public email addresses from a given string. The function should use a regular expression to identify and return a list of email addresses present in the input string. If the input string is empty, the function should return an empty list.
  assert extract_emails("My email is john@example.com and yours is john@gmail.com.")==['john@example.com', 'john@gmail.com']
  assert extract_emails("Contact us at support@company.com for more information.")==['support@company.com']
  assert extract_emails("There are no emails here.")==[]
  assert extract_emails("")==[]
output: import re
  
  def extract_emails(text):
      if not text:
          return []
      pattern = r'\b[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\.[A-Z|a-z]{2,}\b'
      return re.findall(pattern, text)