Projects should be posted on your I5 Web account under the name "assign3.html"
Be sure to email email@example.com to turn in your assignment.
New: Here are some cards to help you out - if you haven't already designed your own!
Part A. By checking a cookie, see if anyone has ever played this game of Blackjack on this machine. If not, ask them their name. If they have, greet them by name and tell them how many "Blackjacks" they have gotten in total so far. (Hint: Get this part to work after you have the other parts up and running!)
When the screen is first seen, only the "backs "of the two cards are visible. Each time you press the on screen button, two more cards are dealt. (By the way, your layout and colors do NOT have to match my example!)
Once you have dealt the two cards, in a FORM, you should print out the POINTS for each of the two cards, and the TOTAL POINTS for the hand. You should also keep a running count of the number of hands which have been dealt. Note again, that it IS possible for the same two cards to be picked! [Also add a counter which counts the number of identical pairs.]
Note that I have provided screenshots of my working example, since I couldn't actually post the solution...
(Hint on picking the card and finding its "points": I have carefully chosen the card names as being "2hearts.gif" through "14hearts.gif". Thus, you will choose a random number from 2 thorugh 14, and display the appropriate card. For cards 2 through 11, the POINTS will thus be equal to the hand number. Only for cards 12hearts.gif, 13hearts,gif and 14hearts.gif will this differ. For each of those three cards, the number of POINTS will be equal to 10. When you proceed to total the points for the hand, however, remember the problem of having two aces!)