GIDForums  

Go Back   GIDForums > Computer Programming Forums > CPP / C++ Forum
User Name
Password
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

 
 
Thread Tools Search this Thread Rate Thread
  #1  
Old 04-May-2007, 09:48
an1 an1 is offline
New Member
 
Join Date: May 2007
Posts: 1
an1 is on a distinguished road

Xchange machine


Hi!
Could anyone help me with the following problem:

I´m supposed to create a class XChangeMachine thea defines a struct, Currency, which contains ints that describes an amount of coins. A member
variable of type Currency should be used to represent the coins left in the Xchangemachine. The machine should not hold any coins when constructed. The XchangeMachine should have a header and a source file
2) It should, however, be possible for the owners to fill up the coin reserve, so I would need a function, that takes an enum type and an int as arguments: void add_coins(CoinType c, int amount).
3) The user should like to be able to tell, at any given time, how much change is left in the machine. Therefore I need an member function, void print(), that prints to the terminal how much change is left in the machine.


Thanks!

A
 
 

Recent GIDBlogFirst week of IA training by crystalattice

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Save a file to a floppy on a SCO Unix machine powerserg CPP / C++ Forum 0 22-Jul-2005 07:14
Changing monitors on a Linux machine JdS Computer Software Forum - Linux 10 23-Dec-2004 09:49
apache server cannot access through another machine benluo Apache Web Server Forum 0 13-Jul-2004 19:28
Wayback machine releases the recall search engine jrobbio Web Design Forum 2 12-Sep-2003 14:40

Network Sites: GIDNetwork · GIDWebHosts · GIDSearch · Learning Journal by J de Silva, The

All times are GMT -6. The time now is 22:52.


vBulletin, Copyright © 2000 - 2008, Jelsoft Enterprises Ltd.