[Tutor] What's the invalid syntax? Code supplied

Nathan Pinno falcon3166 at hotmail.com
Thu Aug 4 03:59:24 CEST 2005


See my latest message for how I fixed this error and got another in its 
place.
----- Original Message ----- 
From: "Nathan Pinno" <falcon3166 at hotmail.com>
To: "Danny Yoo" <dyoo at hkn.eecs.berkeley.edu>
Cc: "Tutor mailing list" <tutor at python.org>
Sent: Wednesday, August 03, 2005 7:48 PM
Subject: Re: [Tutor] What's the invalid syntax? Code supplied


> The only thing I see there is [0] and [1]. Should that be passcard 
> instead?
> ----- Original Message ----- 
> From: "Danny Yoo" <dyoo at hkn.eecs.berkeley.edu>
> To: "Nathan Pinno" <falcon3166 at hotmail.com>
> Cc: "Tutor mailing list" <tutor at python.org>
> Sent: Wednesday, August 03, 2005 7:36 PM
> Subject: Re: [Tutor] What's the invalid syntax? Code supplied
>
>
>>
>>
>> On Wed, 3 Aug 2005, Nathan Pinno wrote:
>>
>>> What wrong with the following syntax?
>>>
>>>
>>> out_file.write(site+","+sitelist[site][0]+","+sitelist[site][1]"\n")
>> [text cut]
>>> It highlighted the last " if that will help any.
>>
>>
>> Take a close look at the end of the line.  Here, I'll underline it:
>>
>>    out_file.write(site+","+sitelist[site][0]+","+sitelist[site][1]"\n")
>>                                                  ^^^^^^^^^^^^^^^^^^^^^
>>
>> Do you see anything unusual there?
>>
>>
> _______________________________________________
> Tutor maillist  -  Tutor at python.org
> http://mail.python.org/mailman/listinfo/tutor
> 


More information about the Tutor mailing list