RSS Forums RSS
Please support our C++ advertiser: Programming Forums

Class with use of <vector>

Join Date: Apr 2004
Posts: 3,808
Reputation: Dave Sinkula is a glorious beacon of light Dave Sinkula is a glorious beacon of light Dave Sinkula is a glorious beacon of light Dave Sinkula is a glorious beacon of light Dave Sinkula is a glorious beacon of light Dave Sinkula is a glorious beacon of light 
Rep Power: 17
Solved Threads: 147
Colleague
Dave Sinkula's Avatar
Dave Sinkula Dave Sinkula is offline Offline
long time no c

Re: Class with use of <vector>

  #30  
Jun 5th, 2005
>Also, the numbers are read from the keyboard, not const integers.

Yes. I tire of repeatedly entering the same information for such examples. The point is that somehow numbers are gathered, then they are sorted, then more are added, and the they are resorted.

>Problem is, the exercise mentions the combination of operator< and the sort algorithm.

You need operator< to use sort.

>I don't see how I have to combine those two to get them into one list.

I don't think they are intertwined like you appear to believe. I think the exercise is trying to be simple, you have have way overcomplicated it.
High Plains Blogger #plains #lounge ## I, for one, welcome our new socialist overlords.
"Capitalism is the unequal distribution of wealth. Socialism is the equal distribution of poverty."
Reply With Quote  
Forums | Blogs | Tutorials | Code Snippets | Whitepapers | RSS Feeds | Advertising
All times are GMT -4. The time now is 2:08 pm.
Newsletter Archive - Sitemap - Privacy Statement - Acceptable Use Policy - Contact Us
Forum system based on vBulletin Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC