0
What is the difference here between print and return
Using 'print' gives everything while using'return' only prints '5'..why? https://code.sololearn.com/c0SsebgwP0Hm/?ref=app
2 Respostas
+ 4
return ends a function call, so the rest of the loop is never executed.
+ 4
return and print are different in every way, print is just like telling someone to repeat what you say while return is just like sending someone on an errand and having them deliver what you want to either you or who ever you want em to deliver it to