print vector without iterator

 copy(nums1.begin(),nums1.end(),ostream_iterator<int>(cout," "));

Comments

Popular posts from this blog