#include <stdio.h> #include <math.h> int main() { int a,b,c; scanf("%d %d %d",&a,&b,&c); int sum=a+b+c; int product=abc; double average=sum/3.0; printf("%d %d %.2f\n",sum,product,average); return 0;
}
#include <iostream> #include <cstring> #include <algorithm> using namespace std; int main() { int a , b ,c; cin >> a >> b >>c; cout << (a + b + c) <<" " <<(a * b * c)<<" "; double avg = 1.0*(a + b + c) / 3; printf("%.2f",avg); }
使用您的 QLUOJ 通用账户