The playersHand
function incorrectly treats a card value of 0
as 10
, which is not in line with standard blackjack rules.
In the playersHand
function, the condition if (cardValue == 0 || cardValue >= 10)
incorrectly maps 0
to a value of 10
. This misinterpretation can lead to incorrect hand value calculations for the player.
This incorrect calculation may lead to an unfair game, as the player's hand value would be artificially inflated, potentially altering the game outcome.
Manual Code Review
Update the condition to correctly handle the card values. 0
should not be treated as 10
. The logic should ensure that the card value is correctly interpreted.
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.