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.
you need to optimize your code, so that it could run less than
12000ms
.Error "Process was terminated. It took longer than 12000ms to complete"
What is needed here?
To be more explicit: Are you sure you want to
return
inside the loop?Your issue. You deleted the
module Codewars.Kata.Unique where
line.Fixed
to the string characters
How many times does the loop execute?
Unable to submit this kata. Server error or memory error.
This comment is hidden because it contains spoiler information about the solution
It's a bit tricky to see without the indentation. (Try wrapping your code in tripple backticks to make it look better.)
I think that your code probably wouldn't pass
is_merge("ab", "b", "a")
, which should beTrue
. Maybe it will be clearer if you figure out why.Good luck and let me know if you want more specific help. :-)
This comment is hidden because it contains spoiler information about the solution
Your code is correct, your return statement for evil is incorrect.
Your code is returning "Battle Result: Evil triumphs over Good", and it should be "Battle Result: Evil eradicates all trace of Good".
The values you see are quantities of each value, not the value itself.
Each "troop" has a specified value (in the description), you don't just add it up. You forgot to mutiply the corresponding value for each race, giving their final good score and final evil score.
Read the Kata description fully if you have a problem with a Kata - "Even though my solution is correct".
Example:
This comment is hidden because it contains spoiler information about the solution
Python 2.7 version works perfectly fine. There should be an error when no code is entered within the function because functions by their very definition can't be empty.
Loading more items...