Python coding

Dennis Lee Bieber wlfraed at ix.netcom.com
Sun Nov 27 22:09:44 EST 2022


On Sun, 27 Nov 2022 16:47:29 -0600, Karen Park <jkpark at mymts.net> declaimed
the following:

>I am trying to do a python code. Using Windows, I got as far as the step that asks me to “copy the logistics.py file and save it in the same folder that you are running python from” (as displayed by the command prompt). 
>Can you help direct me where to go to copy and save this “logistics.py“ file?

	Well, where do the instructions tell you to obtain "logistics.py"? Or
maybe that is the file you are supposed to create using some editor?

	Unless you've changed directories, opening a command shell should
reveal something like:

Microsoft Windows [Version 10.0.19044.2251]
(c) Microsoft Corporation. All rights reserved.

C:\Users\Wulfraed>

... C:\Users\Wulfraed	would be the directory in which to save the file
(for my machine)... But if I run a few directory changes...

Microsoft Windows [Version 10.0.19044.2251]
(c) Microsoft Corporation. All rights reserved.

C:\Users\Wulfraed>cd "Documents\_Hg-Repositories\Python Progs"

C:\Users\Wulfraed\Documents\_Hg-Repositories\Python Progs>

... means the directory to save in would be 
C:\Users\Wulfraed\Documents\_Hg-Repositories\Python Progs

	The idea is to save the .py file in the /current working directory/.
That way you only need to type the name of the file, without the long
directory path, when invoking the program (which assumes 'python"
[python.exe] is on your system path).


-- 
	Wulfraed                 Dennis Lee Bieber         AF6VN
	wlfraed at ix.netcom.com    http://wlfraed.microdiversity.freeddns.org/


More information about the Python-list mailing list