3 ms·
I love and use Python every day, but I agree with Chris that in Swift's case, over using if and else as expression can hurt. In Swift's case, that line is extre
by yeukhon 11y ago
I love and use Python every day, but I agree with Chris that in Swift's case, over using if and else as expression can hurt. In Swift's case, that line is extremely ugly.
If I were to catch an exception, I rather catch it at a line level in a block.
If you read through https://mail.python.org/pipermail/python-ideas/2015-September/036489.html https://mail.python.org/pipermail/python-ideas/2015-Septembe... (a freakin long debate) you will see that sometimes simplifying things can hurt, although in this very debate if/else expression is favor over the proposed new syntax in that PEP, which I am against.