Return statement
In computer programming, subprograms (functions) will "return" to the higher-level programs, which called them; return ends the current task.
In C++, return <X>; (where <X> is an expression) is a statement of code which tells a function to return the execution, of the program, to the calling function, and report the value of <X>. If the function does not have a return type (returns void), the return command can be used without a value to just break out of the current function and return to the calling one.
Syntax
Return statements come in many shapes. The current syntaxes are most common:
As used in Java and C++:
return value;
As used in Smalltalk:
^ value
As used in Lisp:
(return value)
