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.
However, x.length === o.length it doesn't work for me. Maybe you meant x?.length === o?.length
This comment is hidden because it contains spoiler information about the solution
You must also aware of how in operator works because it is not only work on its parent object it is also works on object prototype chaining so let's say that property name already exists in object prototype then it will generate bug to your code
You can make your code shorter by using template literals instead of concatenating it with + operator
because of this code i now understand what this codes do unlike from the first one it is readable for beginners like me
this is better practice because in real life cases you might wanna change the letter "r" into something else...
and in his solution just changing the letter "r" will do it...
I wonder why this code becomes best practices and clever!
Its nice because it is a short code but next time you should avoid ternary operator with more than one condition
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
You need to put a simple checking here if it is equal to zero then return the number if its not give its opposite number
This solution will work but if you leave the parameter as empty it will return false but i considered that the input should be boolean so its not a big deal tho
This comment is hidden because it contains spoiler information about the solution
you can skip the if else statement just return the value but if you are beginner and dont know much about ternary operator then go for it
i really like this solution when it comes to checking if its even or odd because it is more readable and maintainable
Loading more items...