#include using namespace std; //MY functioning code //int main() //{ // float radius; // float height; // cout << "Enter cylinder radius " << endl; // cin >> radius; // cout << "Enter cylinder height " << endl; // cin >> height; // float volume = (3.14) * (radius * radius) * (height); // cout << "Your cylinder's volume is " << volume; // return 0; //} //MY code with 1 syntax error and 1 logic error //int main() //{ // float radius; // float height; // cout << "Enter cylinder radius" << endl; // cin >> radius; // cout << "Enter cylinder height"; << endl; // cin >> height; // bool volume = (3.14) * (radius * radius) * (height); // cout << "Your cylinder's volume is " << volume; // return 0; //} //Partner's code with 1 syntax error and 1 logic error //int main() { // // do // { // float cylinderR = 0; // float cylinderH = 0; // float pi = 3.1415; // std::cout << "What is the height of your cylinder?\n"; // std::cin >> cylinderH; // std::cout << "What is the Radius of your cylinder?\n"; // std::cin >> cylinderR; // float cylinderTotal = pi * cylinderH * cylinderR + cylinderR; // std::cout << "The volume of your cylinder is " << cylinderTotal << ".\n" // } while (true); //} //Partner's corrected code //int main() { // do // { // float cylinderR = 0; // float cylinderH = 0; // float pi = 3.1415; // std::cout << "What is the height of your cylinder?\n"; // std::cin >> cylinderH; // std::cout << "What is the Radius of your cylinder?\n"; // std::cin >> cylinderR; // float cylinderTotal = pi * cylinderH * (cylinderR * cylinderR); // std::cout << "The volume of your cylinder is " << cylinderTotal << ".\n"; // } while (true); //}