Created
February 22, 2016 21:32
-
-
Save meshell/08dc2464495d0663ac77 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
#include <iostream> | |
#include <vector> | |
int main() { | |
std::vector<int> v = {0, 1, 2, 3, 4, 5}; | |
for(const auto& i : v) { | |
std::cout << i << ' '; | |
} | |
std::cout << '\n'; | |
int a[] = {0, 1, 2, 3, 4, 5}; | |
for(const auto& n : a) { | |
std::cout << n << ' '; | |
} | |
std::cout << '\n'; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment