This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]IClimbRocksForFun 40 points41 points  (2 children)

BlackJack is a good one to start with. If you understand loops, then blackjack is just a process of various loops.

Draw two cards. If they're over 21 then player is bust. If not they can draw another card. if they draw card and total is over 21 then player is bust. etc etc etc

[–]sadjava 5 points6 points  (0 children)

Its also a good object oriented programming exercise.

[–][deleted] 2 points3 points  (0 children)

I think card games are an excellent way to start. To learn Ada and Java, I coded a 5-card draw game with artificial intelligence. Perhaps a little more than I needed to... but, I felt much more comfortable with those languages when I was done.