LoginSignup
1
1

More than 5 years have passed since last update.

キーボード入力 + デバッグコンソールを使用する(VSCode(Python))

Posted at

はじめに

  • 当記事は下記の環境にて動作を確認しています。
    1. Python 3.6.2
    2. Visual Studio Code 1.16.1(64bit)

結論

integrated Terminal/Console を選択してデバッグを実行しよう!


サンプルコード

test.py
# テスト用コード

tempStr = input('文字を入力してください')
print(tempStr)

サンプルコードの実行

sample.gif


解決方法

sample.gif

ターミナルから起動するようになりますので、そっちでinputに対する入力が可能になります。
なお、この状態でもデバックコンソールはそのまま使えます。


参考URL

gidhubの対象ページ

https://github.com/DonJayamanne/pythonVSCode/wiki/Capture-User-Input-via-input%28%29-or-raw_input%28%29

1
1
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
1
1