Am tryibg to go through this topic but i dont know what is the problem since evrything is correct

function testSize(num) {

// Only change code below this line

if(num < 5){

return 'tiny'

}else if(num < 10){

return 'Small'


else if(num < 15){

return 'Medium'


else if(num < 20){

return 'Large'


else if(num >= 20){

return 'Huge'




return "Change Me";

// Only change code above this line



Hello and welcome to the community :smiley:!
In the future to post your code as well as a link to the step use the ‘help’ button which appears next to the ‘reset’ button after unsuccessfully submitting your code a few times:

Your code is in fact correct. The issue is a syntax error:(This doesn’t allow the code to be tested even if some conditions are met. Always check the console for errors when your code can’t run.)

As you can see your quotation marks are curly instead of straight as they should be:
you can use either single or double marks but they have to be straight:

"hello" or 'hello'

Btw your text ‘tiny’ should be with an uppercase ‘T’.
Edit: I think your brackets are ok in the actual step but look different in the post. It might just be your lowercase ‘t’ which is causing the error.

1 Like

All the return strings should have the proper case.

testSize(0) should return the string Tiny

@anon86258595 Just a heads up, the forum will do that to code when it isn’t formatted properly. So if you see code like that it will often have the wrong type of quotes.

But people do sometimes write their code in some Wordpad app or on a phone where it can happen.

I’ve edited your code for readability. When you enter a code block into a forum post, please precede it with a separate line of three backticks and follow it with a separate line of three backticks to make it easier to read.

You can also use the “preformatted text” tool in the editor (</>) to add backticks around text.

See this post to find the backtick on your keyboard.
Note: Backticks (`) are not single quotes (').

1 Like

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