answersLogoWhite

0


Best Answer

// macro definitions:

#define PI 3.14159265358979323846

#define CIRCUMFERENCE(radius) (2. * (radius) * PI)

// use this as in CIRCUMFERENCE(21.34)

User Avatar

Wiki User

βˆ™ 11y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: How do you write a c program to calculate the circumference of the circle using macros with parameters?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

C program on how to calculate circumference of a circle?

int radius = 2; int output; radius = radius * 2; output = radius * Math.PI; Console.WriteLine(output);


How do find the circumference of a circle?

The formula; 2 * Pi * Radius = circumference Will calculate the circumference of a circle.


If a circle has a diameter of 8 cm then what is the circumference of the circle?

A simple formula to calculate the circumference of a circle: so in this case:


Pi can be used to calculate the blank of a circle?

Pi can be used to calculate the area of a circle Pi can be used to calculate the circumference of a circle


How do you calculate circumference of a circle?

You use a protractor.


Why you are using pi to calculate circumference of the circle?

Because the ratio of the circumference to the diameter of every circle is pi. So circumference = pi*diameter.


How do you calculate the diameter and the circumference of a circle?

Doubling the radius will give the diameter and times this by pi will give the circumference of the circle.


How do you calculate the circumference of a circle given the diameter or the radius?

Circumference = diameter*pi


IF the circumference of a circle is 6.28 what is the area?

The circumference and area of a circle, with radius r is: circumference = 2*pi*r and area = pi*r2 Use the first to calculate r and then the second to calculate the area.


Why do we use pi?

We use it to calculate the circumference of a circle.


What is the ciruumference of a circle?

The circumference is essentially the perimeter of the circle, or the distance around the circle. To calculate the circumference of a circle, use the formula C = 2 * pi * r. Circumference = two times pi times the radius of the circle.


How do you calculate circumference and area of pi?

Pi is the number of times the diameter of a circle will fit into the circumference. Pi is not a circle, and does not have a circumference or area. To calculate a circumference USING pi, the circumference is diameter * pi. To find the area using pi, area = pi * radius * radius