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.
This comment is hidden because it contains spoiler information about the solution
not boring solution ;)
could u explain pls?
This so funny LMAO. I love how this guy made a one liner solution so freaking complicated
Kata.solution("huh?");
how do you test this im main? i mean how do you call the method?
Futhermore, to avoid NPE, use the expected String as first argument:
"needle".equals(haystack[i])
e1 += e2 translates into e1 = (T) (e1 + e2), where T is a type of e1. In this case, the implicit cast crops double into int, which might lead to a not-very-easy-to-find bug:
int num = 1;
double d = 9999999999d;
num += d;
this is strange. When I write this code:
int num1 = Math.pow(1,2);
I will get an error message which says: "Cannot convert from double to int".
But why does this notation ->> num1+ += Math.powe(); <<-- works?
if you rewrite this to -> num1 = num1 + Math.pow(); <<- it wont work!
Could you please explain?
The way of C
tell me why?!?