I don’t know exactly what I’m missing, but the code dosen’t seem to pass.
I keep getting the message " If a small straight is rolled, your checkForStraights function should enable the fourth radio button, set the value to 30 , and update the displayed text to , score = 30 ."
one thing you can do to check if your code is working as expected is to temporarily change this line of code to something like:
checkForStraights([2,3,1,6,4]);
Then click the roll button and see which radio buttons your code will enable.
(the small straight and the last radio button should both get enabled if your code is working)
from the given instruction, how does small straight pass with this call checkForStraights([2,3,1,6,4]), I thought it had to be either in an ascending or descending order. Please make it clearer to me.
when you roll the dice, the dice may land in any order.
the function checkForStraights should check the dice array to see if the dice rolls form a straight (in any order)
why don’t you re-read the step and then come back and tell me what you think it means and then if that is incorrect, I will let you know?
I am not sure what it would help for me to repeat the same description that is already given in the step.