It has to be something little or a bug

Tell us what’s happening:
made this code from scratch following what fcc has taught and it is like I am not writing any code at all

Your code so far

var count = 0;

function cc(card) {
// Only change code below this line
switch (card) {
case 2:
case 3:
case 4:
case 5:
case 6:
case 10:
case "J":
case "Q":
case "K":
case "A":

if (count > 0){
return count + "Bet";
} else {
return count + "Hold";

// Only change code above this line

// Add/remove calls to test your function.
// Note: Only the last will display
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/79.0.3945.117 Safari/537.36.

Challenge: Counting Cards

Link to the challenge:

test seems to pass if you want to see your return statement wrap console.log(cc(2)) for instance and you will see “1 bet”

You have a small error in the strings you are returning.

Use console.log() with the the test function calls at the bottom of the code so you can see what you are returning and where the error is. Compare the logged string to what the example says the output should be.

Like this: