On 16/03/2016 01:55, jj0gen0i...@gmail.com wrote:
You have apparently mistaken me for someone who's worried.  I don't use Python, I was 
just curious as to why a construct that is found, not only to be useful in 95% of other 
languages, but is generally considered more flexible and readable than the if-elif, was 
missing in Python.  (your link "Switch Statement Code Smell" not withstanding)

Have a great day :)


So you would rather write something like:-

switch (x):
  case COW:
    moo()
    break

  case DUCK:
    quack()
    break

  default IDUNNO:
    panic()

than:-

x.makeNoise()

?

--
My fellow Pythonistas, ask not what our language can do for you, ask
what you can do for our language.

Mark Lawrence

--
https://mail.python.org/mailman/listinfo/python-list

Reply via email to