Cod sursa(job #2923071)
| Utilizator | Data | 11 septembrie 2022 13:45:26 | |
|---|---|---|---|
| Problema | A+B | Scor | 100 |
| Compilator | cpp-64 | Status | done |
| Runda | Arhiva de probleme | Marime | 0.47 kb |
#include <iostream>
#include <fstream>
/*
void execute(){
std::fstream myFile;
myFile.open("adunare.in");
int a, b;
myFile >> a;
myFile >> b;
a += b;
myFile.close();
myFile.open("adunare.out");
myFile << a;
myFile.flush();
myFile.close();
}
*/
int main(){
std::ifstream in("adunare.in");
std::ofstream out("adunare.out");
int a, b;
in >> a >> b;
out << a + b;
in.close();
out.close();
return 0;
}