Category Archives: Function

Area of Circle using function

for formula: http://www.mathsisfun.com/area.htm

code:

We have to always remember that value that define is always pass from main function to customized function named by user so here r=3 is passing to function britto and then the britto formula pi*r*r is applying and returned the value and it is printed in the main function where the variable defined as khetrofol.

Here pi declared as global variable with it’s value.