Re: Python keywords

2007-04-26 Thread Alex Martelli
gtb <[EMAIL PROTECTED]> wrote: > Have done some searching but have not found a place where I can look > up python keywords. >>> import keyword >>> keyword.kwlist ['and', 'as', 'assert', 'break', 'class', 'continue', 'def', 'del', 'elif', 'else', 'except', 'exec', 'finally', 'for', 'from', 'global

Re: Python keywords

2007-04-26 Thread gtb
On Apr 26, 1:59 pm, "Hamilton, William " <[EMAIL PROTECTED]> wrote: > > -Original Message- > > From: [EMAIL PROTECTED] > [mailto:python- > > [EMAIL PROTECTED] On Behalf Of gtb > > Sent: Thursday, April 26, 2007 1:50 PM > > To: [EMAIL PROTECT

Re: Python keywords

2007-04-26 Thread gtb
Thanks Marc. -- http://mail.python.org/mailman/listinfo/python-list

RE: Python keywords

2007-04-26 Thread Hamilton, William
> -Original Message- > From: [EMAIL PROTECTED] [mailto:python- > [EMAIL PROTECTED] On Behalf Of gtb > Sent: Thursday, April 26, 2007 1:50 PM > To: python-list@python.org > Subject: Re: Python keywords > > On Apr 26, 10:16 am, Larry Bates <[EMAIL

Re: Python keywords

2007-04-26 Thread gtb
On Apr 26, 10:16 am, Larry Bates <[EMAIL PROTECTED]> wrote: > gtb wrote: > > Have done some searching but have not found a place where I can look > > up python keywords. I was looking at a script that contained the > > following line: > > > assert self.getResponseCode() in (200, 304, 302) > > > I c

Re: Python keywords

2007-04-26 Thread Marc 'BlackJack' Rintsch
In <[EMAIL PROTECTED]>, gtb wrote: > Have done some searching but have not found a place where I can look > up python keywords. I was looking at a script that contained the > following line: > > assert self.getResponseCode() in (200, 304, 302) > > I can infer the usage here but previously I had

Re: Python keywords

2007-04-26 Thread Larry Bates
gtb wrote: > Have done some searching but have not found a place where I can look > up python keywords. I was looking at a script that contained the > following line: > > assert self.getResponseCode() in (200, 304, 302) > > I can infer the usage here but previously I had thought that "in" was > o

Re: Python keywords vs. English grammar

2006-05-24 Thread Roy Smith
In article <[EMAIL PROTECTED]>, Boris Borcic <[EMAIL PROTECTED]> wrote: > Roy Smith wrote: > > and all three keywords are verbs, so when you describe the code, you can > > use the same English words as in the program source, "You try to execute > > some code, but it throws a foo, which is caug

Re: Python keywords vs. English grammar

2006-05-24 Thread Boris Borcic
Roy Smith wrote: > I noticed something interesting today. In C++, you write: > > try { >throw foo; > } catch { > } > > and all three keywords are verbs, so when you describe the code, you can > use the same English words as in the program source, "You try to execute > some code, but it thr

Re: Python keywords vs. English grammar

2006-05-24 Thread bruno at modulix
defcon8 wrote: > 1. Does it matter? > 2. Is it affecting your productivity. > 3. Are you not trying to programme? > 4. It is open source, change it and stop whining. > What about trying emacs +x doctor ? -- bruno desthuilliers python -c "print '@'.join(['.'.join([w[::-1] for w in p.split('.')]

Re: Python keywords vs. English grammar

2006-05-24 Thread defcon8
1. Does it matter? 2. Is it affecting your productivity. 3. Are you not trying to programme? 4. It is open source, change it and stop whining. -- http://mail.python.org/mailman/listinfo/python-list

Re: Python keywords vs. English grammar

2006-05-24 Thread John Salerno
Roy Smith wrote: > try { >throw foo; > } catch { > } > try: >raise foo > except: But which one is prettier? ;) -- http://mail.python.org/mailman/listinfo/python-list

Re: Python keywords vs. English grammar

2006-05-24 Thread Duncan Smith
Roy Smith wrote: > I noticed something interesting today. In C++, you write: > > try { >throw foo; > } catch { > } > > and all three keywords are verbs, so when you describe the code, you can > use the same English words as in the program source, "You try to execute > some code, but it thr

Re: Python keywords vs. English grammar

2006-05-24 Thread Rony Steelandt
I'm not a english speaker, so I just accepted it...; I understood it as : 'Try' allways to execute this code, 'except' when it doesn't work do this > I noticed something interesting today. In C++, you write: > > try { >throw foo; > } catch { > } > > and all three keywords are verbs, so