#include <iostream>
using namespace std;
int main ()
{
int Num1,Num2,Num3;
cout << "Please enter the first integer value: ";
cin >> Num1;
cout << "Please enter the second integer value: ";
cin >> Num2;
cout << "Please enter the third integer value: ";
cin >> Num3;
cout<<"The sum is"<<Num1+Num2+Num3<<".\n";
cout<<"The product is"<<Num1*Num2*Num3<<".\n";
return 0;
}
dagdag mo na rin to for average
cout<<"The average is"<<(Num1+Num2+Num3)/3<<".\n";
//Iostream kasi kukuha tayo ng input sa user pati mag lalabas din tayo ng output
#include <iostream>
//eto naman po para sa standard namespace
using namespace std;
main(){
//isang number lang po since di naman i-ooutput yung value ng tatlong number.
int number;
//yung sa total po kelangan naka initialize para di undefined yung value.
int total=0;
//same din po sa product
int product = 1;
for (int i=1;i<=3;i++){
cout << "Value of number " << i << ": ";
cin >> number;
total = total + number;
product = product * number;
}
cout << "SUM: " << total << endl;
cout << "AVERAGE: " << total/3 << endl;
cout << "PRODUCT: " << product << endl;
}
