Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
Make sure you're closing you curly braces and parentheses right. AFAIK the js tests are working fine.
Something seems to be not working right with the interpreter. My code is 10 lines long (a for loop with an if inside) but when I run the sample test it generates this stack trace:
/home/codewarrior/index.js:22
})})f;
^
SyntaxError: Unexpected identifier
at createScript (vm.js:80:10)
at Object.runInThisContext (vm.js:139:10)
at Module._compile (module.js:616:28)
at Object.Module._extensions..js (module.js:663:10)
at Module.load (module.js:565:32)
at tryModuleLoad (module.js:505:12)
at Function.Module._load (module.js:497:3)
at Module.require (module.js:596:17)
at require (internal/module.js:11:18)
at [eval]:1:1
I have no idea where it's getting "})})f" from. What the heck is going on?
Also, give an example of the error messages you receive, I don't see any serious problems with your code.
Enclose your code in triple backticks as shown here (second example). It seems some of the symbols in your comment don't show up without proper formatting.
No, unless your solution works, no other user can see it. For cases like that, paste your code using proper markdown and mark your post as having spoiler content.
Oh, I see. Thank you!
That's not the input value, you're returning the result of dividing 3 by 56 (the error message is:
your function output
should beexpected value
) instead of returning the fraction.Okay. But, I am recieving this error:
'0.05357142857142857' should equal '3/56'
why is the numerator 3 when all characters are not in "abcdefghijklm" and the length of the string is 19?
You have to calculate how many characters of the string are not in
"abcdefghijklm"
.I am not sure I understand the question correctly. The code to be written is only supposed to check when there is a bad control string and return the ratio, correct?