Sail E0 Webinar
Question

What is the output of this program?

#include < iostream >

using namespace std;

#define PI 3.14159

int main ()

{

float r = 2;

float circle;

circle = 2 * PI * r;

cout

Options:
A .  12.566
B .  13.566
C .  10
D .  compile time error
Answer: Option A


In this program, we are finding the area of the circle by using concern formula.



Was this answer helpful ?
Next Question

Submit Solution

Your email address will not be published. Required fields are marked *

Latest Videos

Latest Test Papers