No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.
3 Posted Topics
Hello guys, My problem is that my code will automatically go through: [code]if((ask[i].getPrice()) <= (buy[j].getPrice())){[/code] where ask and buy are vectors. I need to know how I am suppose to compare them based upon the getPrice()...... Thanks in Advanced. The rest of the code is here: [code] int i=(int)ask.size(); int … | |
Hello, I cannot figure out why my program crashes when it gets to the code below. Everything else in my coding works, except when I go to run this code... [code] void Auctioneer::matchingGame(){ vector<Trader>::iterator it; int i=ask.size()-1; int x=0; int y=0; int bId; int tId; char h; int temp=0; int … | |
Having trouble trying to copy the vector 'sel' in main to vector 'ask' in class A. Can someone either explain or show me? Thanks in Advance![code]class A{ private: public: vector<Trader> ask; void AskMatchList(vector<Trader>&); void showAuct(); }; void A::AskMatchList(vector<Trader> &list){ vector<Trader>::iterator it; f1= new Trader; //I understand this is the WRONG … |
The End.