View Full Version : Need Help

04 April 2007, 11:59 PM
I need help with my C++ homework, I understand couple of them but not most of them.
1. make two private enumerated data types that will store name of a color
2. two constructors one accept no formal parameters and sets the flag red and white. second constructors accept two of enumerated data type and set color accordingly.

I did number 1 but i don't understand how to do number 2 can you please help me.

04 April 2007, 08:51 AM
1. i suggest you google "enum" - once you understand that it is very straightforward - plus have a think about how you would store the name of something - char/int/string/double/float?? once you understand the underlying concepts then it will be very easy

2. your red/white flag is going to be using your enum - so as long as you do some research on enums and constructors you'll be fine. For your second constructor you need 2 parameters so once again get googling on constructors to understand this

PS - in the future i suggest you post things like this on a c++ forum rather than a graphics forum

CGTalk Moderation
04 April 2007, 08:51 AM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.