6 ms·
print("2. Fork out this code, suggest improvements and submit those") There fixed it for you :)
by craigts 16y ago
print("2. Fork out this code, suggest improvements and submit those")
There fixed it for you :)
- ciupicri 16y agoThey might be using RHEL (Red Hat Enterprise Linux) which comes with Python 2.4 and in 2.4 you can't use print as a function. LE: python 2.5 -> 2.4 (bconway was right)
- bconway 16y agoTwo corrections: A.) RHEL 5.x (by default) comes with Python 2.4, not 2.5. B.) Yes you can. It is required in 3.x, though.
- kingkilr 16y agoWell you can't use it as a function. You can however combine the parsing of the "print" keyword, and the "(" and ")" taking precedence around the string to form KEYWORD STRING that looks a hell of a lot like a function call though.
- deleted 16y ago[deleted]
- koenigdavidmj 16y agoActually, print(one single argument) works the same in both Python 2 and 3.
- ciupicri 16y agoDo you mean as in x = (x) = ((x)) = ...? In this case you're right, although it's still not a function.