Re:Numpy: Plan for dropping Python 2.7 support
by dagw on Thursday November 16, 2017 @05:16AM
(#15711523)
I wouldn't call it awful, but it is slightly annoying. In a dynamically typed language it's hard to know apriori if a variable is an int or a float with a whole number value and you end up having to write x/float(y) all over the place just to make sure your code does what you want it to do.
The new case of / always being float division and // always being integer division just makes everything more explicit.
Re:Numpy: Plan for dropping Python 2.7 support
by OskarS on Thursday November 16, 2017 @10:02AM
(#15713110)
This particular language quirk I don't think has anything to do with dynamic typing: it's equally annoying in C-style languages where 3/2 and 3/2.0 mean different things.
The new case of / always being float division and // always being integer division just makes everything more explicit.