Basic JavaScript - Replacing If Else Chains with Switch

Tell us what’s happening:
Hi. When I click on Run the tests (ctrl + Enter), nothing happens. It gets stuck. I can’t submit my tests. Not only in Javascript tests but also in HTML tests. This happens when I start editing the function. Then it freezes and I can’t run the tests anymore.
Your code so far

function chainToSwitch(val) {
  let answer = "";
  // Altere apenas o código abaixo desta linha
case


  // Altere apenas o código acima desta linha
  return answer;
} 

chainToSwitch(7);

Your browser information:

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

Challenge: Basic JavaScript - Replacing If Else Chains with Switch

Link to the challenge:

Please Tell us what’s happening in your own words.

Learning to describe problems is hard, but it is an important part of learning how to code.

Also, the more you say, the more we can help!

Hi. When I click on Run the tests (ctrl + Enter), nothing happens. It gets stuck. I can’t submit my tests. Not only in Javascript tests but also in HTML tests. This happens when I start editing the function. Then it freezes and I can’t run the tests anymore.

  • does that happen with some code in it? or it happens when there is no code in it?
  • did you try using any other browser?

happy learning :slight_smile:

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.