View Code of Problem 47

#include <stdio.h>
#include <iostream>
#include <string.h>
#include <string>
#include <algorithm>
#include <iomanip>
#include<vector>
#include<math.h>
using namespace std;
int main()
{
	int a, b, c;
	cin >> a >> b >> c;
	int x, y;
	double z;
	x = a + b +c;
	y = a * b*c;
	z = x / 3.0;
	cout << x << " " << y << " ";
	cout << fixed << setprecision(2) << z;
}

Double click to view unformatted code.


Back to problem 47