📜  python flask 示例应用程序 - Python 代码示例

📅  最后修改于: 2022-03-11 14:46:07.224000             🧑  作者: Mango

代码示例3
#Import Flask, if not then install and import.

import os
try:
  from flask import *
except:
  os.system("pip3 install flask")
  from flask import *

app = Flask(__name__)

@app.route("/")
def index():
  return "

Hello World

" if __name__ == "__main__": app.run(host="0.0.0.0", port=8080, debug=False)