#include <iostream>
#include <vector>
using namespace std;
void iterate(int *arr, size_t count) {
for (int n : vector<int>(arr, arr+count)) {
cout << n << endl;
}
}
int main() {
int arr[] = {1, 2, 3, 4, 5};
iterate(arr, 5);
return 0;
}
I2luY2x1ZGUgPGlvc3RyZWFtPgojaW5jbHVkZSA8dmVjdG9yPgp1c2luZyBuYW1lc3BhY2Ugc3RkOwoKdm9pZCBpdGVyYXRlKGludCAqYXJyLCBzaXplX3QgY291bnQpIHsKCWZvciAoaW50IG4gOiB2ZWN0b3I8aW50PihhcnIsIGFycitjb3VudCkpIHsKCQljb3V0IDw8IG4gPDwgZW5kbDsKCX0KfQoKaW50IG1haW4oKSB7CglpbnQgYXJyW10gPSB7MSwgMiwgMywgNCwgNX07CglpdGVyYXRlKGFyciwgNSk7CglyZXR1cm4gMDsKfQ==