by CodeChum Admin
Multiplying two numbers is a piece of cake, but how about multiplying three of them, either being a negative of positive number? With programming and proper code, these tasks are easy to handle.
#include <iostream>
#include <string>
using namespace std;
int main()
{
float pieceCake1;
float pieceCake2;
float pieceCake3;
cout<<"Enter three piece of cake: ";
cin>>pieceCake1>>pieceCake2>>pieceCake3;
float product=pieceCake1*pieceCake2*pieceCake3;
cout<<"Product: "<<product<<"\n\n";
system("pause");
return 0;
}
Comments
Leave a comment