Closed Ndiedrick21 closed 2 years ago
I think it makes more sense to put it at the hand level, because the value of an ace only changes in the context of a hand. The PR I made assumes that it will be an 11 unless the player would bust. In an RL context, this may be tricky either way, since the policy doesn't know if the player has an ace just based on the hand value.
I think this code would provide that 1 or 11 functionality, but I think there could be an overall better solution out there.
I think we are doing two separate things here:
I think both are in the Hand Class but I think the first should be addressed separately which will make the second cleaner
Check out the update for this. I think the workaround is a bit more intuitive. There shouldn't ever be a reason to change an ace's value back from 1 to 11 again correct? Closing this issue for now since the functionality is provided ... We can keep this in mind and discuss this as an area for improvement but open a new issue if we want to redesign this since that is a separate task.
Do you think the solution for determining whether an ace should be a 1 or 11 should be determined at the Card level or in the Hand Class? I think it does make the most sense to implement this functionality at the hand level since a player should be able to choose whether the ace needs to be either value. Anyone else have any other thoughts?