Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

While loop not being executed in method

 
Sam Thompson
Ranch Hand
Posts: 93
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello everyone:

I am just wondering if some of you can give me a hand in finding out where the problem is in regards to my code. The method I am having trouble with is onTableAfterFlop().

This method simply asks the user to enter the cards face up during a flop in a poker game. From there it will perform various computations and tasks in determining probabilitie and possibilities of different hands.

However, I notice that for some reason the while loop isn't being executed? Can anyone figure out why exactly? I have double checked the parameters and everything looks fine. My code is inserted below:



Can anyone figure out where the obstruction is as to why it isn't working? Otherwise, it would be running fine. The PokerPlayer class is below this line.


Any help would be greatly appreciated.

Thanks everyone!

S.T.
 
Tony Docherty
Bartender
Posts: 2957
59
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
lastCardRecorded is false and so the while statement fails and hence the while loop body doesn't execute.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic