Write a QBASIC program to take input of radius from the user. Calculate and
display Area and Circumference of a circle with a proper message.
Formula
1. Area = 3.14 * radius * radius
2. Circumference = 2 * 3.14 * radius
Answers
Answered by
3
Consider the attachment:
Attachments:
Answered by
2
Question:-
- WAP to take input of radius from the user.
- Calculate and display Area and Circumference of a circle with a proper message.
Code Language:-
- QBASIC
QBASIC CODE:-
CLS
PRINT "ENTER A RADIUS"
INPUT R
C=2*3.14*R
A=3.14*R*R
PRINT "AREA="+A
PRINT "CIRCUMFERENCE="+C
END
Variable Description:-
- R:- to accept Radius as input from the user
- C:- to calculate Circumference
- A:- to calculate Area
Similar questions