On Fri, May 11, 2018 at 12:04 PM, Bob van der Poel <b...@mellowood.ca> wrote: > I agree with my freind Gene! And, if it is really necessary to retain > octal, why not preface it with anything BUT a "0". I've been hit by this a > few times in the past. I used lots of hex over the years, but don't recall > ever using octal ... except in frustrating moments when I needed to change > permission bits.
Because if it doesn't start with a 0, it won't look like a number. You could use &H1A2B for hex (I can't remember what the octal equivalent was), which consumes the ampersand as a syntactic character; or you could put a trailing adornment 1A2Bh, which looks like an identifier if the number starts with a letter. Much cleaner to make the marker "this is octal" or "this is hex" start with a zero, making it very clearly a number from the start. ChrisA -- https://mail.python.org/mailman/listinfo/python-list