You may have only ever used programs like Jupyter Notebook or Python web editors where you just type code in individual windows and it execute it and returns the last expression. This is fine for small projects, but it's not the usual way to run code. Code is typically executed by saving code to a file and passing the file to the python
executable.
When you press the "Run" button in VS Code it will run python
and pass it the current file to execute.
When you create a new file in VS Code (Ctrl-N), or most any text editor, it does not actually write a file. It doesn't know what to call it or where to write it. VS Code calls it "Untitled-1" until you save the file. These are sometimes referred to as "buffers".
When you hit "Run" on a buffer which has never been saved, VS Code prompts you to save the file so it has something to pass to python
.
As written your code will display nothing. Another difference is that if you want anything printed to the screen you have to do that yourself.
name = "Jane Doe"print(type(name))