siteIcon

Tech Novice Tools

PHP Apps

burgerIcon

Yahtzeeyahtzee

Stage 3: Classifying Rolls via
Regular Expressions

About this stage

In this stage, roll the dice and select whichever ones you want to freeze or re-roll. As you do so, PHP will classify each roll and indicate the matched configuration in the scorecard to help you visulize the nature of the roll.

To do this, behind the scenes we will sort the dice and apply some fancy regular expressions.

Because we are not using it yet, we took the liberty of hiding the scorecard with a little CSS.

01/16/20



Trial Count: 0

Roll Count: 0

Sum: 0

Yahtzee Scorecard

Aces:
Twos:
Threes:
Fours:
Fives:
Sixes:
Left Score:
Bonus:
Left Total:
3 of a Kind:
4 of a Kind:
Full House:
Sm. Straight:
Lg. Straight:
Yahtzee:
Chance:
Right Total:

Grand Total: 0