Cod sursa(job #310098)
| Utilizator | Data | 1 mai 2009 19:26:16 | |
|---|---|---|---|
| Problema | A+B | Scor | 100 |
| Compilator | cpp | Status | done |
| Runda | super_easy | Marime | 0.27 kb |
#include<iostream.h>
#include<fstream.h>
using namespace std;
template <class Tip>
Tip suma(Tip A,Tip B)
{
Tip S;
S=A+B;
return S;
}
int main()
{
long a,b;
ifstream f("adunare.in");
ofstream g("adunare.out");
f>>a>>b;
g<<suma(a,b)<<'\n';
return 0;
}