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.
OP solved it, closing
OP solved it , closing
This comment is hidden because it contains spoiler information about the solution
I made the modifications (the java version was really a mess!) and republished it, but the previous soluitons aren't invalidated yet... I don't know if this is just the server which is not up to date or if my modifications won't actually get realmy published because there are already too much completions to the kata... Let's see it in the next days...
Java: Basically same for me. Can some admin have look into this? Seems like there is an issue with Submit tests. Unfortunate to see it not corrected for such a long time.
Some of us are at a level where that is a lot to explain; so thank you for replying to their question.
Magic! :]
But seriously, sloppiness.
There isn't much to explain. How would you calculate
fusc(5)
? Well, 5 = 2 x 2 + 1, andfusc(2 x 2 + 1) = fusc(2) + fusc(3)
.fusc(3) = fusc(2 x 1 + 1) = fusc(1) + fusc(2)
.fusc(2) = fusc(2 x 1) = fusc(1) = 1
. Put these results together and you getfusc(5) = 3
. Your job is to implement the function fusc.I too would like more directions on what this kata is even asking. So I'll just throw this comment in to draw more attention it it!
Fixed
The slope is defined by two points. If numerator and denominator are
0
you only have one point.This comment is hidden because it contains spoiler information about the solution
The items in the array may also be null values. Your code uses
entry == true
but you need to have a null check inside the for loop to check if the current value is a null value. Your code uses try, catch, therefore when a null value is detected in the array, it automatically goes to the "catch" block and returns 0 instead.