Click here to Skip to main content
15,887,135 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more:
Suppose i have 10 elements in vector i need to pass all the 10 elements to command prompt by adding comma to the elements.

vector elements are as shown below.
Example:hi
hello
how
are
you
in the command line it has to be in this format:hi,hello,how,are,you.
is there any solution please help me out.

Thanks in advance
Posted
Comments
nv3 18-Nov-14 7:54am    
Yes, I can confirm that there is a solution to your homework. You can work it out easily by taking a look at your course notes and a C++ text book.

1 solution

 
Share this answer
 
Comments
Sergey Alexandrovich Kryukov 18-Nov-14 9:56am    
Fair enough, a 5.
—SA
I.P.Katti 19-Nov-14 1:07am    
hi,can you give me a small example on my post.
Richard MacCutchan 19-Nov-14 3:10am    
The examples are in the documentation if you look. Here is one: http://msdn.microsoft.com/en-us/library/7fthz5xd(v=vs.100).aspx.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900