To print an integer use the insertion operator
<<
with
cout
:
cout << i << endl;
To print a
vector of integers use the same tecnique while iterating on all the vector items, e.g.
for (size_t n = 0; n < v.size(); ++n)
{
cout << v[n] << " ";
}
cout << endl;
or
for (auto i : v)
{
cout << i << " ";
}
cout << endl;