CAN NOT FIX THIS. PLEASE HELP
10.2 Calculate Volume of a Sphere
Given the formula for volume of a sphere as: Volume= 4/3 * PI *radius^3 Write a program that inputs a radius as a floating pointnumber (double) and outputs the volume as a floating point number.Three places of precision are needed in the output. The value of PI= 3.14.
MY CODE:
#include <iostream>
#include <iomanip>
using namespace std;
int main() {
double radius, pi = 3.14;
cin >> radius;
cout << setprecision(3) << fixed;
double volume = (4.0 / 3) * pi *radius*radius*radius;
cout << “Volume of a Sphere with Radius “<<radius<<“is = ” <<volume;
return 0;
}

Only
PayPal Gateway not configured
PayPal Gateway not configured