Development environments such as anaconda have both the console and then scripting facility integrated under one roof.
Python 3.8.10 (default, Jun 2 2021, 10:49:15) [GCC 9.4.0] on linux Type "help", "copyright", "credits" or "license" for more information. >>>then you can type in commands one by one. Under Windows you might need to point the PATH variable to your python program or you let Anaconda do it for you.
Write your commands in any text editor and save it as a .py-file. However, it's recommended to use an editor which supports at least python's indentation which is a very important feature of python. We'll see that indentation in python defines the body of a function, the content of a loop or the code executed conditionally.
So, it's recommended for any serious work to install an editor which supports python such as spyder, VS-code, py-charm or emacs.
Once you have your script file saved just type “python myscript.py” and it will be executed.
If you need help for a function you can use the in built help function “help(thecommand)” to get help for “thecommand”. Try out “help(print)” to get help for the “print” command.