Cod sursa(job #1662940)

Utilizator ShutterflyFilip A Shutterfly Data 25 martie 2016 12:31:03
Problema A+B Scor 100
Compilator cpp Status done
Runda Arhiva de probleme Marime 0.37 kb
#include <iostream>
#include <stdio.h>
using namespace std;

struct package
{
  int a:16;
  int b:16;
};

int main()
{
    freopen("adunare.in","r",stdin);
    freopen("adunare.out","w",stdout);

    ios_base::sync_with_stdio(false);
    cin.tie(NULL);
    package x;

    int* h=new int;

    cin>>*h;
    x.a=*h;
    cin>>*h;
    x.b=*h;
    delete h;
    cout<<x.a+x.b;
}