+ 1
Return
What does return mean I don’t really get it and what happens if you put the return value to 1
3 Antworten
+ 2
Return was created to return a value.
For example you can created a function:
int count() {
int result=1+2;
return result;
}
int number=count() ; //number = 3
+ 1
In main() {}, return 0 is there to say that your code was correctly executed. But you can change the value.
0
thanks