Build A Boolean Checker

function booWho(value){

 if (value === true){

   return "true"

 }else if (value === false){

   return "true"

   }else {

   return "false"

 }

};

console.log(booWho())

I can’t tell what’s wrong with my code. It runs as expected but it doesn’t seem to be the required answer.

Hi

Can you please post the url of the challenge you are doing.

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

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

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

Should you be returning a string?

Remember, that JavaScript has a built-in Boolean type.

1 Like

Build a Boolean Check Function: Build a Boolean Check Function | freeCodeCamp.org

I’d be glad with any help

have you tried to return boolean values instead of strings?

Thanks, that solved the issue