[Courses] [python] Lesson 1: Hello world

Maria Inmaculada de la Torre idelatorreie at gmail.com
Sat Jun 18 14:46:13 UTC 2011


================= Homework =========================

Normally I'll have programming assignments for homework -- some easy,
some harder. But for this first lesson, I just have a few questions.
Post your answers to the list -- if someone beats you do it, don't
worry about it, you're not being graded on who answers.

1. I'm interested in hearing what version of Python everybody is running,
  on which operating system, distro and version. Please post your results!
  Especially if python3 is the default, or if you have any other problems
  running the examples.

*Python 2.7.1+ in Ubuntu 11.04 (x32)*

2. Why are there two commas in
   print "Hello,", name
   ? What do you think the difference is between them?

*I have no idea for the second one, but I actually run the program without
the second coma (the first coma is part of the text) and it told me there
was "Syntax error: Invalid syntax" and wouldn't run that bit. So cheating a
little bit (I have already read some answers) I'm gonna guess it's for
concatenation purposes or as a way of separating variables from non
variables.*

3. Anyone know why the language as named Python?
*I'm cheating in this one :P, I search in Wikipedia and the answer was " the
origin of the name (based on the television series Monty Python's Flying
Circus <http://en.wikipedia.org/wiki/Monty_Python%27s_Flying_Circus>**)".*

Thanks so much for taking the time of doing this course and many thanks for
the first lesson. :)


More information about the Courses mailing list