Hacker News new | ask | show | jobs
by jrkatz 3254 days ago
I tend to like ternary operators and similar operations but the way python handles it really bothers me, I think because it essentially overloads the `if` keyword, and totally violates the if-then-else norm of conditional statements (ternary operator included). then-if-else is stranger than a do-while loop, but at least there's an occasional reason to use a do-while loop.
1 comments

It bothers me a little, as well. I tend to think of it as a special type of comprehension, since it follows that format as opposed to the standard if statement.