QBASIC PROGRAM TO FIN AREA OF TRIANGLE USNG FUNCTION.
DECLARE FUNCTION AREA (IA,B,C)
CLS
INPUT"ENTER FIRST SIDE";A
INPUT "ENTER SECOND SIDE";B
INPUT"ENTER THIRD SIDE";C
AR=AREA(A,B,C)
PRINT'AREA OF TRIANGLE=";AR
END
FUNCTION ARE (A,B,C)
AREA=(S*(S-A)*(S-B)*(S-C))^(1/2)
END FUNCTION
DECLARE FUNCTION AREA (IA,B,C)
CLS
INPUT"ENTER FIRST SIDE";A
INPUT "ENTER SECOND SIDE";B
INPUT"ENTER THIRD SIDE";C
AR=AREA(A,B,C)
PRINT'AREA OF TRIANGLE=";AR
END
FUNCTION ARE (A,B,C)
AREA=(S*(S-A)*(S-B)*(S-C))^(1/2)
END FUNCTION
Comments
Post a Comment