Quiz for Chapter 12

Don't continue if you have not yet understand the lesson

Time : 15 min

Make a unit consist of functions that convert binary numbers into decimals and vice versa, also hexadecimal numbers to decimals, vice versa. Use it in a sample program.
Hints : Use strings for output for binary and hexadecimal numbers.

Time : 45 min

Rebuild your black jack and poker game. You must build a unit for the cards since both games use cards. You must at least provide :

  1. ShuffleCard for shuffling the deck, especially at the beginning.
  2. RetrieveCard retrieve a card, return 0 for no card is left.
  3. DrawCard (cardtype; x,y)
    This draws cardtype card at x,y.
    Example : DrawCard(JackofSpade,14,5) will draw Jack of Spade at 14,5

You must hide as much information as possible inside the unit, prevents user to modify your status.

That's all ! Good bye !


Where to go ?

Back to chapter 12
Advance to chapter 13, about text files.
To lesson 1 contents
My main tutorial homepage
My programming links
Contact me here


By : Roby Joehanes, © 1997, 2000