input: Write a function to list the contents of a directory. If the directory path is not provided, use the current working directory. Return a list containing all the contents of the directory.
  assert list_directory_contents('my_dir')==['file1.txt', 'file2.txt', 'folder1']
  assert list_directory_contents('missing_dir')==[]
  assert list_directory_contents('')==['file3.txt', 'file4.txt', 'folder2']
  assert list_directory_contents()==['file5.txt', 'file6.txt', 'folder3']
output: import os
  
  def list_directory_contents(directory=None):
      if directory is None:
          directory = os.getcwd()
      if not os.path.exists(directory):
          return []
      return os.listdir(directory)