Thread: about inset value in vector

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Registered User
    Join Date
    Jan 2006
    Posts
    141
    hi cat....first of all, that is just a name which i used to insert vector of string...

    from ur reply, u mean use sorting method to sort ? i dont really understand about ur reply... cheers/\.

  2. #2
    Registered User
    Join Date
    May 2003
    Posts
    1,619
    Quote Originally Posted by peter_hii
    hi cat....first of all, that is just a name which i used to insert vector of string...

    from ur reply, u mean use sorting method to sort ? i dont really understand about ur reply... cheers/\.
    A std::set will sort all the entries based on operator<, so if you create your own class, you make your own operator< and you can then do whatever you want.
    You ever try a pink golf ball, Wally? Why, the wind shear on a pink ball alone can take the head clean off a 90 pound midget at 300 yards.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. can some one please tell me the cause of the error ?
    By broli86 in forum C Programming
    Replies: 8
    Last Post: 06-26-2008, 08:36 PM
  2. syntax help?
    By scoobygoo in forum C++ Programming
    Replies: 1
    Last Post: 08-07-2007, 10:38 AM
  3. Vector class
    By Desolation in forum C++ Programming
    Replies: 2
    Last Post: 05-12-2007, 05:44 PM
  4. Need some help/advise for Public/Private classes
    By nirali35 in forum C++ Programming
    Replies: 8
    Last Post: 09-23-2006, 12:34 PM
  5. Certain functions
    By Lurker in forum C++ Programming
    Replies: 3
    Last Post: 12-26-2003, 01:26 AM