I’ve tried typing mkdir lpthw and the terminal said that it was an invalid syntax. Do you guys know what’s wrong.
**Thank you so so muchhhhh:heart_eyes:
I’ve tried typing mkdir lpthw and the terminal said that it was an invalid syntax. Do you guys know what’s wrong.
**Thank you so so muchhhhh:heart_eyes:
Hello @Rosellia.
There is no problem with your command "mkdir lpthw”. But it is a unix command.
So you cannot do this in a “python-terminal”. At least not that way.
Start your terminal (perhaps it is called ”console” in Mac).
Navigate to where you want to create this folder ”cd home/your_name/”
Create it with the command ”mkdir lpthw”
Then navigate in to it with ”cd lpthw”.
Now you can start to write your python files in here with your favourite text editor.
Adding to this, usually when you run a python script, you’ll tell the terminal which software to run (i.e. Python) and then the file to execute.
python3.6 app.py
But many languages have built in ways to run the language directly in the terminal. When you just run
python3.6
You are telling the terminal to run that built-in interpreter. You can see it is running by the build numbers etc, and it usually starts with
>>>
As ulfen69 says, this is ‘inside’ python and not the normal command line where Unix commands will work.
So, pretty common mistake and a few people gave you suggestions but I’ll explain a little differently:
~ anchi$
prompt you see there. That’s where you type these bash commands.You should also watch my video as I do this and it’s way easier to see someone work a bash shell than to read about what to do.
Thank you so much. That was really easy to understand. May I ask where I can watch a video of you working on a bash shell?
Hi @Rosellia.
I guess you could login at Zed’s web site Learn Code The Hard Way and down load his videos that comes with the book.
You could also search for “bash mkdir” on Youtube.
You will get tons of results. Most of them are about Linux.
But you can use them in your Mac too. All of the basic commands are the same in Linux and Mac.