At Sunday 2004-12-19 20:44, you wrote:
Yep. If you're going where I think you're going (binary search), I was about halfway through the modifications when I opened the email.
actually I hadn't considered binary search at all, I was thinking that perhaps a modification to set_difference() might do the trick. I don't mean a _small_ modification either, but if the lists are already sorted maybe there's a chance.
Lack of sleep will get to you... :(
On Sun, 19 Dec 2004 20:22:01 -0700, Victor A. Wagner Jr.
wrote: At Sunday 2004-12-19 17:54, you wrote:
This seems like the type of thing boost may have an answer to, yet I still havn't found it:
I have two std::lists, about 50,000 items in each. The items are all number ranges so two uints start and end. I need to remove one list from the other - exact matches or subranges only. Currently I'm using remove_if() to remove/shrink/split them but it is taking forever, around 30sec.
Anyone know of a better solution?
are the lists sorted?
-- Cory Nelson http://www.int64.org _______________________________________________ Boost-users mailing list Boost-users@lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users
Victor A. Wagner Jr. http://rudbek.com The five most dangerous words in the English language: "There oughta be a law"
_______________________________________________ Boost-users mailing list Boost-users@lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users
-- Cory Nelson http://www.int64.org _______________________________________________ Boost-users mailing list Boost-users@lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users
Victor A. Wagner Jr. http://rudbek.com The five most dangerous words in the English language: "There oughta be a law"