To create a shortcut for quickly running Python code in VS Code, follow these steps:
- Go to the extensions panel and search for “Code Runner” - install the yellow icon.
- Immediately save changes and reload VS Code
- Then press control alt and n. Now the output will show up.
- Change the command to python3 in user settings if you’re on Mac.
- Save the changes and you’re done!