LoginSignup
10
3

More than 3 years have passed since last update.

Python初心者がマイクロフレームワークFlaskを使って30秒でHello Worldしてみた

Last updated at Posted at 2019-12-02

Flaskとは

about me

Python歴

3日

やった理由

楽しそう

やったこと

①Flaskインストール

pip install Flask

②好きなフォルダにhello.pyを作る
③以下を貼り付ける

from flask import Flask
app = Flask(__name__)

@app.route('/')
def hello_world():
    return "Hello World!"

if __name__ == '__main__':
    app.run()

④実行

python hello.py

http://127.0.0.1:5000/ にアクセス
スクリーンショット 2019-12-02 20.00.33.png

参考

Flask

10
3
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
10
3