Cod sursa(job #1266643)
Utilizator | Data | 18 noiembrie 2014 22:57:38 | |
---|---|---|---|
Problema | A+B | Scor | 100 |
Compilator | cpp | Status | done |
Runda | teme_upb | Marime | 0.36 kb |
// A+B.cpp : Defines the entry point for the console application.
//
#include <stdio.h>
int main()
{
FILE *InAB = NULL;
FILE *OutAB = NULL;
int a = 0;
int b = 0;
int sum = 0;
InAB = fopen("adunare.in", "r");
OutAB = fopen("adunare.out", "w");
fscanf(InAB, "%ld\n%ld", &a, &b);
sum = a + b;
fprintf(OutAB, "%ld", sum);
return 0;
}