Pagini recente » Profil Tatomir Alex - atatomir | Profil LORDEN | Cod sursa (job #949939) | Cod sursa (job #1230458) | Cod sursa (job #1707401)
typedef struct _iobuf
{
char* _ptr;
int _cnt;
char* _base;
int _flag;
int _file;
int _charbuf;
int _bufsiz;
char* _tmpfname;
} FILE;
extern "C"
{
FILE* fopen (const char*, const char*);
int fclose( FILE *fp );
int fscanf (FILE*, const char*, ...);
int fprintf (FILE*, const char*, ...);
}
int main()
{
FILE *in = fopen ("adunare.in", "r"),
*out = fopen ("adunare.out", "w");
int a, b;
fscanf (in, "%d %d", &a, &b);
fprintf(out, "%d", a+b);
fclose (in);
fclose (out);
}