input: def generate_web_app(app):
      """ Create a Flask web application that takes user input via a form on a home page
      and generates an HTML page displaying the input text.
      >>> app = generate_web_app(Flask(__name__))
      >>> app.run(debug=True)
      """
output:     from flask import Flask, render_template, request
  
      @app.route('/')
      def home():
          return render_template('index.html')
  
      @app.route('/generate', methods=['POST'])
      def generate():
          user_input = request.form['user_input']
          return render_template('display.html', text=user_input)
  
      return app