[ create a new paste ] login | about

Link: http://codepad.org/5x8FmWYR    [ raw code | output | fork ]

tauk - C++, pasted on Oct 22:
1
2
3
4
5
6
7
8
9
10
11
#include<iostream>
using namespace std;

int main() {
   int a = 1; int b = -1;
   int *e = &a; int *f = &b;
   *e = a + *f;
   e = f;
   cout << "a = " << *e << endl;
   cout << "b = " << *f << endl;
}


Output:
1
2
a = -1
b = -1


Create a new paste based on this one


Comments: