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.
A result like this is not possible as there are only three values involved. So the result would always be something like .0, .33333 or .66666. The next full point will never be reached, so there is no need to use a double.
I just forked it, and it passed all tests.
i tried to run it and its returning false;
I don't think nesting ternaries is a good practice. It makes code harder to read.
I believe a more verbose and a less "cool" solution with a series of ifs would be more dev friendly.
This comment is hidden because it contains spoiler information about the solution
Me... when I saw this solution, after spending an hour doing it the hard way: https://www.youtube.com/watch?v=PFr-kNbXHew&ab_channel=HuffPost
This is a great one line return with a ternary. Maybe I am just too new but I feel like really long ternarys like this are more confusing than helpful to read.
Awesome Solution!
I had a similar solution. To make this a little easier on the eyes I would recommend using parenthesis.
Has unnescessary imports, it's but still clever.
It's awful.
This Solution is very clever!
After setting i to 1 circle of loop finished and next line of code that will be executed is i++. So, yes, in begining of next circle of loop i will be equal to 2
Sorry. I am new here. Next time I will.
Use spoiler flag next time, please.
Loading more items...