+ 1
Python . What does make sense to Put in the function the command Return cause .....
.print(seconds) return seconds the result must be nothing but the result is still "seconds" but just explain me why do I should to use return sometimes in the functions
4 odpowiedzi
0
The return is used in cases where you have to save a value to use it in other blocks of codes, sometimes you don't really need to return something because you won't need the value, you just need to print it on screen.
When you don't return a value is called a void function, that's something that you will not see on python but I recommend you learn the basics of C++, C# or Java to can understand better this kind of subjects.
Have a nice day 🧏🏼♀️🧏🏼♀️🧏🏼♀️
0
Ariadne Rangel thank you , and how I will know where is the new Block of Codes??
0
Kir-Py the blocks of code are basically the classes and functions on your script.
It's a bit complicated explain it here so feel free to send me a DM if you have doubts.
🙇🏼♀️🙇🏼♀️🙇🏼♀️