A function procedure is a small manageable and functional part of a program that performs special tasks and returns a single value to the main module or calling module. A function program is written using the FUNCTION- END FUNCTION statement.
Syntax of FUNCTION-END FUNCTION:
FUNCTION name (parameters/Arguements)
<block of statement>
Name = result
END FUNCTION