Login Register






Python Tutorial Chapter 2 - More Python filter_list
Author
Message
RE: Python Tutorial Chapter 2 - More Python #5
NIce work but I have some suggestions about your tutorial,

1) Your explanation about Functions in Python is not clear and lacks proper examples

2) You've mention under the Commonly used functions as

Code:
Commonly used Functions 1.print() 2.input() / raw_input() 2.float 3.complex

This might confuse beginners as they will think all of them are separate functions like input() and raw_input(). You should have mentioned the Input() is used in Python3.3 and raw_input() in previous version that's 2.7. I recommend you write functions about single python versions that you are using otherwise beginners are going to get confused.

3) This is just a suggestion, For me whitespaces in code makes it more readable. Your example like:

Code:
>>2+3

If you read other tutorials like Learn Python the Hard Way, they have too stated it's better to leave spaces so that it's more readible like:

Code:
>>> 2 + 3

For better example here's a simple add function:

No whitespaces

Code:
def addition(x,y): return x+y

With spacing

Code:
def addition(x, y): return x + y

You can see the difference yourself.

4) You didn't mention anything about indentation as it's important for a language like Python, one wrong indent in a long code and a beginner is gonna have a heck of a time finding it.
My Blog: http://www.procurity.wordpress.com
Donations: 1HLjiSbnWMpeQU46eUVCrYdbkrtduX7snG

Reply





Messages In This Thread