insert elements in array in c++11

C++
int main() {
    int array[10];
    for(int &i : array){
        std::cin >> i;
    }
}

Source

Also in C++: