Tell us what’s happening:
Describe your issue in detail here.
Your code so far
this evening the compiler started saying that the my first return statement was outside the function… before that it said that I was getting the first three test correct…also does my last return statement need a closing bracket.
let count = 0;
function cc(card) {
// Only change code below this line
if (card <= 6 ) {
++ count ;
}else if (card == 7 || 8 || 9 ) {
count += 0 ;
}
-- count ;
}
if (count > 0){
return count + " Bet" ;
}
return count + " Hold" ;
return "Change Me";
// Only change code above this line
}
cc(2); cc(3); cc(7); cc('K'); cc('A');
Your browser information:
User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/109.0.0.0 Safari/537.36
hello, thts really nice of you to help but its recommended that we dont give full answer, rather help them to find it our for themselves, its better that way, happy helping
you might want to separate those (i.e. conditions in correct syntax, for example a === b || b === c || ....) individually and try again, happy learning
It is great that you solved the challenge, but instead of posting your full working solution, it is best to stay focused on answering the original poster’s question(s) and help guide them with hints and suggestions to solve their own issues with the challenge.
We are trying to cut back on the number of spoiler solutions found on the forum and instead focus on helping other campers with their questions and definitely not posting full working solutions.