Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » Community » Newbie corner » Algorithms and Vectors
Re: Algorithms and Vectors [message #28138 is a reply to message #28136] Wed, 18 August 2010 16:06 Go to previous messageGo to previous message
dolik.rce is currently offline  dolik.rce
Messages: 1791
Registered: August 2008
Location: Czech Republic
Ultimate Contributor

Hi Javier,

The predicate is basicaly a less than function, not equality. So the code should be
class Predicate{
public:		
	bool operator()(const A& lhs, const A& rhs){
		return lhs.a<rhs.a;	
	}
};


Honza
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Open An image upon startup
Next Topic: Assert failed in core/value.h line 464
Goto Forum:
  


Current Time: Sat Jun 21 22:11:07 CEST 2025

Total time taken to generate the page: 0.03754 seconds