Why gives "k = 09" a syntax error ?
Mensanator
mensanator at aol.com
Wed Oct 29 15:49:34 EDT 2008
On Oct 29, 2:44 pm, Stef Mientki <stef.mien... at gmail.com> wrote:
> Guilherme Polo wrote:
> > On 10/29/08, Stef Mientki <stef.mien... at gmail.com> wrote:
>
> >> hello,
>
> >> Why gives "k = 09" a syntax error ?
>
> > 09 is not a valid octal number. Instead use 011.
>
> > Ok, I guess you were not aware that prefixing a number with a '0'
> > would cause python to parse it as an octal and now you know.
>
> thanks guys,
> I didn't realize there were still people using octal notation ;-)
Windows users don't have much need for it, but it's still
popular with the 'Nix crowd.
>
> cheers,
> Stef
More information about the Python-list
mailing list