Cod sursa(job #2487766)

Utilizator matei.antohieAntohie Matei matei.antohie Data 5 noiembrie 2019 18:33:23
Problema A+B Scor 100
Compilator cpp-64 Status done
Runda Arhiva de probleme Marime 0.25 kb
#include <iostream>
#include <fstream>
using namespace std;

int main()
{
    int x,sum=0;
    ifstream f("adunare.in");
   while(f>>x){
    sum +=x;
   }
   f.close();
   ofstream g("adunare.out");
   g<<sum;
   g.close();
    return 0;
}