Review Algorithmic Thinking by Building a Dice Game - Step 10

Tell us what’s happening:

I know there might be several correct ways to achieve the same results. That’s what makes tutorials so difficult to “pass” I seem to achieve the desired outcome but it still says it does not pass.

Your code so far

<!-- file: index.html -->

/* file: styles.css */

/* file: script.js */
// User Editable Region

let selectedValue = 0;
let achieved = 0;
scoreInputs.forEach(radio => {
  radio.addEventListener("change", (event) => {
  selectedValue = event.target.value;
  console.log(selectedValue + "selected value");
  achieved = event.target.id;
  console.log(selectedValue+" acheived  " + achieved);
  })
});

keepScoreBtn.addEventListener("click", (event) => {
  if(selectedValue) {
    updateScore(selectedValue, achieved);
    resetRadioOptions();
  } else {
        alert ("Please select a hand.");
    }  
}); 

// User Editable Region

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/131.0.0.0 Safari/537.36

Challenge Information:

Review Algorithmic Thinking by Building a Dice Game - Step 10

You should not be adding new global variables on this step