3 ms·
In case the grandparent doesn't realize, 2.x has a print statement not function.
by montecarl 13y ago
In case the grandparent doesn't realize, 2.x has a print statement not function.
- ma2rten 13y agoI meant function as in functionality. This is really pointless nitpicking.
- yukichan 13y agoKnowing the difference between functions and statements is not pointless nitpicking. Not in the least.
- ghshephard 13y agoNormally I would agree with you - but one of the epic changes between 2.x and 3.x python, was the change of print from a statement to a function - so, in this case, it's not so much nitpicking as pointing out one of the major changes between the two streams of python.
- anaphor 13y agoActually it's a procedure because it has a side-effect.
- dragonwriter 13y agoIn python, they are called "functions" whether or not they have side effects. (And, actually, in most programming languages I've seen that have different constructs called "function" and "procedure", the difference is that functions have a return value and procedures don't -- usually, both can have side effects.)
- anaphor 13y agoHave you ever used a functional programming language?