Hi there! So I tought my code was wrong, and searched the forums and passed the code I found there and it still does not let me pass the test and move on. Maybe I’m missing something so here is the code:
var count = 0;
function cc(card) {
// Only change code below this line
switch(card){
case 2:
case 3:
case 4:
case 5:
case 6:
count++;
break;
case 10:
case 'A':
case 'J':
case 'Q':
case 'K':
count--;
break;
}
// Only change code above this line
}
if(count > 0){
return count + 'Bet';
}else{
return count+ 'Hold';
}
// Add/remove calls to test your function.
// Note: Only the last will display
cc(2); cc(3); cc(7); cc('K'); cc('A');
Anyone who could help me?