Please ignore secret bonuses. Secret tests do NOT award bonus. Max hw grade is 30+2 bonus efficiency

Do you need help?

Getting started with Python

angelo.spognardi (8170 points)
75 155 224
in News by (8.2k points)

Hi all! Since we have some spare time before starting, you can take a look at our guide Lesson 0: getting started with Python, on the website of the course. Comments and feedback are welcome! See you soon!

968 views

2 Answers

S
Simone99_ (1180 points)
22 50 60
by (1.2k points)
hi,

where can we find this guide exactly? can't find it into course section, thanks!
angelo.spognardi (8170 points)
75 155 224
by (8.2k points)

You should click on the link above, the one like this --> Lesson 0: getting started with Python

A
Alessio_Borgi (660 points)
0 2 6
by (660 points)
Dear professor,

As regards "How to use the command line" section, towards the end of the section, where it is written the "Warning", I was wondering if we could avoid to use double quotes renaming the "Python Script" directory. What I just would like to know is if it is possible to rename in a rude way this directory maybe adding an underscore between the two word or maybe there is a way to rename it without doing damages. I know that it is strongly not recommended to use white space in both file names and directories. In this case, it is a little different becouse the directory was already named. In that case, if the aswer is positive, it will change something in the command syntax? Do we have to use the double quotes yet?   

I have also another question. I have just started to have a look at "Think Python". In the "How to use the Python interpreter" section you have written that "//" is used for the whole division. In the book it is written that "//" is the Floor Division operator that has the ability to divide two number and rounds down to an integer. It is correct what the book says?.

The last thing is that I've done the exercise/challenge at the end of the lesson. Could I send you a message where I add my Python file? Or is there an alternative way you would prefer to receive it?

Thank you for your time.

Best Regards
angelo.spognardi (8170 points)
75 155 224
by (8.2k points)
Hi, nice to have someone already at work (even in a saturday!). Straight to the points:
1. we had to use double quotes only because there are white spaces in the path and, mainly in Linux, this can create some troubles (generally when using scripts). It is better to avoid rude renaming in directories created during an installation; much better option, as you suggest, simply avoid having directories with white spaces. If there are no white spaces, we can omit the double quotes, like python C:\mydir\university\programming\exercise.py, however this is quite rare in Windows, where white spaces in directory names is very popular. As a final note, the example was mentioning a program ran with the full, absolute path, but generally we will use the relative path, namely we "cd" into the directory of the script and run python exercise.py directly in there.
2. "//" is the operator you mention, however, it does not divides two numbers, but one number for another number. As we will see, the nice thing about it is that a//b returns the lowest integer c such that c *b <= a
3. Of course, please send it to me if you think there is something interesting to observe in your solution.