DECLARE FUNCTION DISTANCE(A,T,U)
CLS
INOUT"ENTER ACCELAERATION";A
INPUT"ENTER TIME";T
INPUT"ENTER INITIAL VELOCITY";U
PRINT"DISTANCE TRAVALLED BY BODY";DISTANCR(A,T,U)
END
FUNCTION DISTANCE(A,T,U)
S=U*T+1/2*A*T^2
DISTANCE=S
END FUNCTION
No comments:
Post a Comment