Does Python need a '>>>' operator?
Just van Rossum
just at xs4all.nl
Sun Apr 14 04:23:13 EDT 2002
In article <Prau8.17347$vF6.558738 at news2.tin.it>,
Alex Martelli <aleax at aleax.it> wrote:
> [ ... ] Indeed, given the small amount of bit-twiddling in
> typical Python usage, I think & ~ | ^ are already overboard -- they
> make a lot of sense in C, a very low-level language that is used a
> LOT for bit-twiddling, but, in Python, named built-in functions might
> have been more appropriate in hindsight (fewer precedence levels to
> remember) -- if not, even, functions in a separate module.
Although I agree with the bit-twiddling argument, I find that
overloading these operators is *very* useful to get a compact (and
readable) spelling for set-like operations (union, section, etc.).
Just
More information about the Python-list
mailing list