def p(s):print(s)
def f():
r=float(input("r:"))
a=3.14159265*r*r
p("A="+str(a))
f()Tier 1 · geometry
Circle Area
Area from radius.
Files (1)
How to use it
Launch CIRCLE from the prgm key. The program prompts once for the radius.
r:— enter the radius (any units; the output area is in those units squared).- Press
enter. - You'll see
A=with the area value.
Uses π ≈ 3.14159265, so results match a standard 8-digit calculator.
Example problem
A circular table has a radius of 2 feet. What's its area in square feet?
- Run
CIRCLE. - At
r:type 2, pressenter. - Output:
A=12.5663706.
The area is ≈ 12.57 ft². Verify: π·r² = 3.14159 · 4 = 12.566. ✓
TI-84 Plus CE — try before committingoff
TI-84 Plus CE
(calculator off) Press ON to start.
Test cases (1)
| ID | Inputs | Expected contains |
|---|---|---|
| r-2 | 2 | A=12.5663 |