Last active
August 29, 2015 14:23
-
-
Save LoganBarnett/65ddfefd95eb1cb33dd9 to your computer and use it in GitHub Desktop.
Post incremental hell
This file contains hidden or 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 foo = 0; | |
int bar = foo++; | |
print(foo); // <= ? | |
print(bar); // <= ? | |
// 5,000,000 ints of 10 | |
std::vector<int> stuff(5000000, 10); | |
// do you know what's in the var 'it'? Is it safe to copy lots and lots? | |
for (std::vector<int>::iterator it = stuff.begin(); it != stuff.end(); it++) { | |
std::cout << ' ' << *it; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment