0

2+2

When i run , is not output. Why?

29th Apr 2018, 10:12 AM
Lewsijght G
Lewsijght G - avatar
2 Answers
+ 3
2 + 2 result is 4, but Python code requires the print() function to produce any output, using print function is easy: print(2 + 2) Propably because there might often be a lot of calculations in Python code and coder propably won't it to print out all of the calculations, but coder can make it to print anything coder wants it to print.
29th Apr 2018, 10:29 AM
Seb TheS
Seb TheS - avatar
+ 1
try: print(2 + 2)
29th Apr 2018, 10:19 AM
Ulisses Cruz
Ulisses Cruz - avatar