Ka-Ping Yee wrote: > > On Sun, 30 Jan 2000, Tim Peters wrote: > > If this goes in (I'm not deadly opposed, just more opposed than in favor), > > I'd like to see "else" used instead of the colon (cond "?" true "else" > > false). The question mark is reasonably mnemonic, but a colon makes no > > sense here. > > I agree with that sentiment (along the lines of the philosophy that > chose "and" over "&&"), and it seems to me that it makes the most sense > to use words for both: > > a = x > 0 then x else -x I would favorise this as well instead of using ?: . Maybe it would make sense to be even more verbose and use an "if" as well? a = if x > 0 then x else -x sign = lambda x: if x > 0 then 1 elif x then -1 else 0 ciao - chris -- Christian Tismer :^) <mailto:tismer@appliedbiometrics.com> Applied Biometrics GmbH : Have a break! Take a ride on Python's Düppelstr. 31 : *Starship* http://starship.python.net 12163 Berlin : PGP key -> http://wwwkeys.pgp.net PGP Fingerprint E182 71C7 1A9D 66E9 9D15 D3CC D4D7 93E2 1FAE F6DF we're tired of banana software - shipped green, ripens at home
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4