4 ms·
I started reading about Python long before I began programming in it (partially due to a deeply terrible book on the topic I purchased). I ran across the integ
by at_a_remove 5y ago
I started reading about Python long before I began programming in it (partially due to a deeply terrible book on the topic I purchased). I ran across the integer division bit and stopped cold. "That," I remember thinking, "is a language feature they will change."
- leephillips 5y agoIs that because you didn’t have experience with other languages? Because integer division in python2 worked in the way I had come to expect from Fortran, etc.
- at_a_remove 5y agoNo, precisely the opposite: it is because I have tons of experience with many other languages. I get why some people think a default integer division is a good idea. I do. Having said that, it was clear that Python was aiming itself at being a kind of glue language wherein various functions were obvious, and integer division is not obvious to someone picking up programming for the first time. If I walk up to someone and ask "What's three divided by two?" I would expect more "One and a half" answers than "Two goes into three just the one time."