Created
June 26, 2016 21:24
-
-
Save olafurw/bbc650e891cd860c26d2f083dd2c3e12 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
int main() | |
{ | |
int x = 4; // vanilla variable | |
int& y = x; // reference to the one above | |
int* z = &x; // pointer, without having to teach them about malloc or new, that can come later, just complicates things at first | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment