I think this challenge have a bug.
See original GitHub issueChallenge Return Early Pattern for Functions has an issue.
User Agent is: Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/47.0.2526.80 Safari/537.36 Core/1.47.933.400 QQBrowser/9.4.8699.400
.
Please describe how to reproduce this issue, and include links to screenshots if possible.
My code:
// Setup
function abTest(a, b) {
// Only change code below this line
if(a<0||b<0)
{
return typeof(c);
}
// Only change code above this line
return Math.round(Math.pow(Math.sqrt(a) + Math.sqrt(b), 2));
}
// Change values below to test your code
abTest(2,-2);
The Console return “undefined”, but this challenge submit fail.
Issue Analytics
- State:
- Created 7 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
Alphabet Hunt - Bugs Challenge / JustJordan33 - YouTube
Today my family, cousins, and I did the Alphabet Hunt, but with a twist! We get crazy with bugs from Newport Jerky Company!...
Read more >Has the Quick Thinking challenge bug been reported and is ...
I'm doing old tome challenges and on Tome 4 - Level 1 there is a challenge called Quick Thinking and this is where...
Read more >Looks like we've once again got the bug where your Seasonal ...
Looks like we've once again got the bug where your Seasonal Challenges are flashing and you can't stop it. https://i.imgur.com/I5hBq1I.png.
Read more >Challenges not Counting Progress AT ALL now - Bug Report
First these challenges kept resetting and now they are not counting any progress AT ALL!.. “The Best Defense”, “Hold The Line” and “The...
Read more >bug of apple watch series SE
Hi,. I got an apple watch series SE at 27th December. The watch doesn't show the monthly challenges. I thought it will be...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@JamsonKwok It returns “undefined” not undefined. Your if statement should just return
undefined
not the typeof of some undefined variable which will result in a stringified undefined 😄Don’t forget a typeof(typeof(undefined)) is a string.
There’s nothing wrong with the challenge, you can close it.
@marhyorh good catch! @JamsonKwok as @marhyorh has said, the test requires that the return be the key word
undefined
.