Author Topic: Not sure of the wording for this project...  (Read 2651 times)

0 Members and 1 Guest are viewing this topic.

Offline Newby

  • Moderator
  • Hero Member
  • *****
  • Posts: 10877
  • Thrash!
    • View Profile
Not sure of the wording for this project...
« on: June 03, 2009, 04:22:12 am »
But all I have to say is: the STL sucks fat penis.

2. Category class will contain an STL string for its name, an STL multiset of Item sorted by location, and an STL multimap of set Iterators with keys based on the corresponding Item’s price.

So Item looks like:

Code: [Select]
class Item {
  int price;
  string location;
  string description;
};

Not sure what to think of Category, though. I get the first two things.

Code: [Select]
class Category {
  string name;
  multiset<Item> items;
  // ???
};

But "an STL multimap of set Iterators with keys based on the corresponding Item’s price."

I have like, 0 idea how to envision that in my head.

Perhaps something like:

Code: [Select]
multimap<int, set<Item>::iterator> more_items;
I just have no idea what the hell is being asked for there. I can't imagine that data structure in my head. Fuck the STL. :(

Any thoughts?

EDIT -- Here's why I'm confused: as far as I know, an iterator just iterates over its container's type. If I have a set iterator, it needs an iterator to go over. Why would I have a multimap full of random iterators? Don't those iterators need a set to associate with? I'm confused. Bah!
« Last Edit: June 03, 2009, 04:57:01 am by Newby »
- Newby
http://www.x86labs.org

Quote
[17:32:45] * xar sets mode: -oooooooooo algorithm ban chris cipher newby stdio TehUser tnarongi|away vursed warz
[17:32:54] * xar sets mode: +o newby
[17:32:58] <xar> new rule
[17:33:02] <xar> me and newby rule all

I'd bet that you're currently bloated like a water ballon on a hot summer's day.

That analogy doesn't even make sense.  Why would a water balloon be especially bloated on a hot summer's day? For your sake, I hope there wasn't too much logic testing on your LSAT. 

Offline Newby

  • Moderator
  • Hero Member
  • *****
  • Posts: 10877
  • Thrash!
    • View Profile
Re: Not sure of the wording for this project...
« Reply #1 on: June 03, 2009, 06:58:26 pm »
Never mind. Pwned that thing.
- Newby
http://www.x86labs.org

Quote
[17:32:45] * xar sets mode: -oooooooooo algorithm ban chris cipher newby stdio TehUser tnarongi|away vursed warz
[17:32:54] * xar sets mode: +o newby
[17:32:58] <xar> new rule
[17:33:02] <xar> me and newby rule all

I'd bet that you're currently bloated like a water ballon on a hot summer's day.

That analogy doesn't even make sense.  Why would a water balloon be especially bloated on a hot summer's day? For your sake, I hope there wasn't too much logic testing on your LSAT.