I can't pass the JavaScript's step:Use Contional Logic with If Statements

Tell us what’s happening:
Describe your issue in detail here.

  **Your code so far**
function trueOrFalse(wasThatTrue) {
// Only change code below this line
return "Yes,it's true";

return "No,it's false";
var wasThatTrue=true;
// Only change code above this line


many thanks any helper.

  **Your browser information:**

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

Challenge: Use Conditional Logic with If Statements

Link to the challenge:

You where asked to return the strings "Yes, that was true" or "No, that was false". What are you returning?

Its not breaking your code, but what is this doing here?

I type if(wasTahtTure) this statement,so when this statement is true the function trueOrFalse() will return “Yes, that was true” if the function is false it will return “No, that was false” so I type function () { if(){return “Yes, that was true”} return “No, that was false” }
2.Its not breaking your code, but what is this doing here?
var wasThatTrue=true;
above my type ,I only want to set a boolean to match the if condition statement.
3.how to sole this problem?

You wrote this

But that is not correct

Reread more closely what @Lego_My_Eggo is pointing out to you here

You have to use that exact string.

Same issue here
This is incorrect

Reread more closely to the correct string

It looks like you are trying to create a variable called wasThatTrue and assigning true to it.

But the directions do not ask you to add that part.
Plus that part is not getting executed anyway because you placed it after a return statement.

I would just delete this

Hope that helps!

Dear J.:
many thanks!
I also can’t pass. I think I need cool down for few hours so see you soon !

Taking breaks is good.
that gives the brain a rest to try again later :slight_smile:

“wasThatTrue” is a parameter received by the function, so you don’t need to redefine it.