jeudi 29 mars 2018

Why wouldn't it calculate the area?

#include <iostream>

using namespace std;

int main()
{   float y;
    float area;
    float pi = 3.145;
    cout << "Enter the radius" << endl;
    cin >> y;
    area = pow(y,2)*pi;
    cout << "The area = "<< area << endl;
    return 0;
}

what is wrong with my code ?? It supposed to calculate the area of the circuit

Aucun commentaire:

Enregistrer un commentaire