#include <iostream>
#include <vector>
int main()
{
    std::vector<int> v;

    int n;
    while(   v.size() < 10   // while there are less than 10 values entered
          && (std::cin >> n) // and an integer can be read from the input
          && n != 0 )        // and the value entered isn't zero
    {
        v.push_back(n); // remember the value
    }

    std::cout << "The values that were entered: ";
    for(auto n: v)
        std::cout << n << ' ';
    std::cout << '\n';
}
