REM PROGRAM TO DISPLAY TOTAL SURFACE AREA OF HEMISPHERE.

CLS

INPUT “ENTER RADIUS ”; R

A= 3 * 3.14 * R ^ 2

PRINT “TOTAL SURFACE AREA OF HEMISPHERE “; A

END

USING SUB PROCEDURE

DECLARE SUB TSAREA (R)

CLS

INPUT “ENTER RADIUS”; R

CALL TSAREA(R)

END

SUB TSAREA (R)

A= 3 * 3.14 * R ^ 2

PRINT “TOTAL SURFACE AREA OF HEMISPHERE “; A

END SUB

USING FUNCTION PROCEDURE

DECLARE FUNCTION TSAREA (R)

CLS

INPUT “ENTER RADIUS”; R

PRINT “TOTAL SURFACE AREA OF HEMISPHERE ”; TSAREA(R)

END

FUNCTION TSAREA (R)

TSAREA = 3 * 3.14 * R ^ 2

END FUNCTION

## No Comments