"Python Scripts" in command results in "Path Not Found" error

Asked 1 years ago, Updated 1 years ago, 108 views

I'm setting it up while looking at Python's introduction, but I've been stumbling since the beginning. Help me...
First, I downloaded ez_setup.py to Documents > Python Scripts.
Then, at the command prompt,
C: ……Documents PPython Scripts If you type +Enter,
It says, "The specified path cannot be found." What is this?
It's probably an error, isn't it?

It may be very rudimentary, but I would appreciate it if you could explain it to me.

windows command-line

2022-09-30 19:27

1 Answers

Command columns separated by spaces

The basic command column consists of the command and the コマンドcommand-line arguments 「 that you give it.
Command-line arguments may not be required, or multiple can be specified.
Separate them with spaces.

command argument 1 argument 2 argument 3

For example, the cd command is cd .It then receives the directory to be moved as an argument.
If you are moving to the directory Python_Scripts:

cd Python_Scripts

The problem here is if the directory name, which is an argument, contains spaces.
Suppose you tried to navigate to Python Scripts and did the following:

cd Python Scripts

Because this is separated by a blank space, the command is interpreted as cd, the first argument as Python, and the second argument as Scripts.
Therefore, you are instructed to go to the directory Python, and without such a directory, you will get the error "No Path Found".

Not divided by spaces in the quote

There is a rule that double quotes (") do not split strings to address situations like the one above.

cd "Python Scripts"

You can now navigate to Python Scripts

The directory separator in Windows is \"\"

Another problem with the command in question is that the directory is separated by a full-width circle.
The situation in Windows is a little confusing, so please keep the following points in mind.

Unix directory hierarchies are separated by / (slash), but Windows uses \ (backslash).
The letter \ is an inverted slope of /.
However, some environments and fonts are displayed in different characters.
In Windows in the Japanese language environment, a half-width letter with yen is used.


2022-09-30 19:27

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.