input: Write a function to create a REST API in Python that can be used to delete an item from a list. The function should return a Flask application with appropriate routes for retrieving and deleting items.
  assert create_api().delete('/items/Banana')=="{\"message\": \"Item successfully deleted.\"}"
  assert create_api().delete('/items/Mango')=="{\"message\": \"Item not found.\"}"
  assert create_api().get('/items')=="[\"Apple\", \"Orange\"]"
output: def create_api():
      from flask import Flask, jsonify, request
  
      app = Flask(__name__)
      items = ["Apple", "Orange"]
  
      @app.route('/items', methods=['GET'])
      def get_items():
          return jsonify(items)
  
      @app.route('/items/<string:item>', methods=['DELETE'])
      def delete_item(item):
          if item in items:
              items.remove(item)
              return jsonify({"message": "Item successfully deleted."})
          else:
              return jsonify({"message": "Item not found."})
  
      return app