Skip to content

Instantly share code, notes, and snippets.

@temitayopelumi
Last active January 9, 2021 13:13
Show Gist options
  • Save temitayopelumi/75fed6a7adfccb1b23ee4c653ff79002 to your computer and use it in GitHub Desktop.
Save temitayopelumi/75fed6a7adfccb1b23ee4c653ff79002 to your computer and use it in GitHub Desktop.
from flask import Flask #import flask
#The app object
app = Flask(__name__) #create an instance of the app taking in the script name
#route
@app.route('/') #decorates the first view function
def hello_world():
"""Print 'Hello, world!' as the response body."""
return 'Hello, world!'
if __name__ == '__main__':
app.run(debug=True)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment