At 03:52 PM 6/26/2006 -0700, Guido van Rossum wrote: >It's the >messiness of trying to define rules that are as flexible as needed for >optimization and yet claiming to maintain the strict if/elif-chain >semantics. Hear, hear! We already have if/elif, we don't need another way to spell it. The whole point of switch is that it asserts that exactly *one* case is supposed to match -- which means by definition that the *order* of the cases must not matter. It is an unprioritized selection, rather than sequential selection. I think that probably the biggest misunderstanding of switch that has been put forth is that it's shorthand for a particular pattern of if-elif use, when in actuality it's the other way around: if-elif is sometimes used as a crude workaround for the absence of a switch feature.
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