yeyeman9
yeyeman9
  • Threads: 1
  • Posts: 3
Joined: Dec 2, 2009
December 2nd, 2009 at 3:00:23 PM permalink
Hello,

I am writing a java program for a class and I need to be able to determine the odds (percentage) that the player has of winning the hand depending on his cards and the dealers up card. The rule is that the dealer stands on all 17s.

I was wondering if there is some sort of chart that already has this odds, or if there is a math equation for it or something. I will really appreciate any kind of help.

Thanks in advance.
DorothyGale
DorothyGale
  • Threads: 40
  • Posts: 639
Joined: Nov 23, 2009
December 2nd, 2009 at 3:08:21 PM permalink
Are you asking us to do your homework for you??!! Please ...

Given that you are in a first semester freshman level programming course and you know object oriented programming, create classes for a card, deck, hand, and if you like, a basic strategy class and other classes as you find useful. Go look up basic strategy on www.wizardofodds.com and then write a simulation program to complete this.

Or go look up the results (there are a couple of Internet sources, but you should at least do that much research on your own to find them instead of asking -- that pretty much solves your whole project) and write a bunch of System.out.println statements.

--Dorothy

----------------------------------------
DGs Minimally Offensive Signature
"Who would have thought a good little girl like you could destroy my beautiful wickedness!"
yeyeman9
yeyeman9
  • Threads: 1
  • Posts: 3
Joined: Dec 2, 2009
December 2nd, 2009 at 3:21:34 PM permalink
I have been looking for a while now and haven't really found much. Problem here is that I barely know any java because my professor pretty much sucks. So I have learned it the hard way.

Anyway thats not the problem, the game is already done. You can play blackjack and all that. But the problem comes, what is actually left to be done, on the odds of winning. Depending on what the dealer has and what the player has, I need to determine what is your percentage of probability of winning....
DorothyGale
DorothyGale
  • Threads: 40
  • Posts: 639
Joined: Nov 23, 2009
December 2nd, 2009 at 3:26:26 PM permalink
Run a simulation -- have the program deal random hands and play them correctly according to basic strategy and the house rules, and keep track of the total wagers and total win per starting hand.

Sorry about your professor -- it can be tough. Some of my best professors were my worst professors, they taught me how to teach myself.

Good luck to you! (And look around at bjmath.com).

--Dorothy

----------------------------------------
DGs Minimally Offensive Signature
"Who would have thought a good little girl like you could destroy my beautiful wickedness!"
yeyeman9
yeyeman9
  • Threads: 1
  • Posts: 3
Joined: Dec 2, 2009
December 2nd, 2009 at 3:31:35 PM permalink
Alright. Thanks. I will see what I can do :S. I really have no idea hehe.

If anyone else has any idea, I will appreciate it.

Thanks again.
pacomartin
pacomartin
  • Threads: 649
  • Posts: 7895
Joined: Jan 14, 2010
January 18th, 2010 at 10:27:35 AM permalink
Take a look at Wizard of Odds Appendix 9, where he tells you the expected value of all the games. Expected value is different than percentage of times you will win because it includes the bonuses for blackjack and assumes that you make the optimal move at all times (including compositionally dependent moves). He also assumes that each deal is done with a fresh deck and that there is no cut card.
  • Jump to: