GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com โ€” CPP-Programs-Code-Bank/Area of Circle at main ยท harshladha/CPP-Programs-Code-Bank

Expand file tree

/

Area of Circle

/
Copy path

Directory actions

More options

More options

Directory actions

More options

More options

Latest commit

 

History

History
History
/

Area of Circle

/
Copy path

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
ARCIRC.CPP
ARCIRC.CPP
 
 
README.md
README.md
 
 

README.md

Outline

Area and Circumference of a Circle

This C++ program calculates and prints the area and circumference of a circle for a given radius.


๐Ÿš€ How It Works

  • Prompts the user to enter the radius r
  • Initializes p = 3.14 (approximate value of ฯ€)
  • Calculates:
    • Area a = ฯ€ * rยฒ
    • Circumference c = 2 * ฯ€ * r
  • Prints both the area and circumference
  • Uses clrscr() to clear the screen and getch() to pause output (Turbo C++ specific)

๐Ÿ“‹ Sample Output

enter radius of circle:5
area of circle is:78.5
circumference of circle is:31.4


๐Ÿ› ๏ธ How to Compile and Run

๐Ÿ’ป Turbo C++ (Windows)

  1. Open Turbo C++ IDE
  2. Go to File > Open, select ARCIRC.CPP
  3. Compile > Run

๐Ÿ“š Concepts Demonstrated

  • Input using cin
  • Arithmetic calculations
  • Using pow() function
  • Basic console output in C++
You are visitor 01402792 โ€” GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800ร—600. No cookies required.