Why does this work:
# start
a = 5
print a, 'is the number'
#end, prints out "5 is the number"
But not this:
# start
a = 5
print a 'is the number'
#end, errors out
The difference here is the comma seperating the variable and the string literal. Is the comma some sort of concatenation operator or is the comma necessary in some form of a requirement in the print function, i.e is the variable a an argument to print as well as 'is th number' another argument to print?
--
Thanks,
Eric
-- http://mail.python.org/mailman/listinfo/python-list