facing problem in running python code in vs code terminal

Viewed 45

i am unable to run python code in terminal on vs code its showing -u what it means? but i can run it in a interactive screen i save then file then also facing the enter image description hereproblem please help

2 Answers

Your Vs Code Window is showing 'No Interpreter'
Try reinstalling python and also I guess vs Code is not Up-to-Date.

The dot on the tab means that the current file is not saved, use Ctrl+S to save the file and then run the code.

You can add the following configuration in the settings.json to realize the function of saving files in real time.

    "files.autoSave": "afterDelay",

What does -u stand for?

-u is an argument to the python command

-u : force the stdout and stderr streams to be unbuffered; this option has no effect on stdin; also PYTHONUNBUFFERED=x

There are more parameters you can get by typing python -h on the command line

enter image description here

Related