Problema medie1 | www.pbinfo.ro

PHOTO EMBED

Wed Feb 15 2023 16:18:59 GMT+0000 (Coordinated Universal Time)

Saved by @takoma2elite #c++

​#include <iostream>
using namespace std;
#include <iomanip>

int main ()
{
    int a, b, c;
    float medie;
    cin >> a >> b >> c;
    medie = (a + b + c) / 3.;
    medie = (int) (medie * 100)/100.;
    cout << fixed << setprecision(2) << medie;


    return 0;
}
content_copyCOPY

da rezultatul cu fix 2 zecimale dupa

https://www.pbinfo.ro/probleme/173/medie1