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 is not a proper way to report a bug in a kata.
If you want to report a bug, you need to:
Your solution not passing tests is not a kata issue.
my tests are passing and the code is correct but keeps giving me when I try 'Attempt'
Fixed tests
Tie
expected 'Battle Result: Good triumphs over Evil' to equal 'Battle Result: No victor on this batt…'
Completed in 2ms
Good wins
expected 'Battle Result: No victor on this batt…' to equal 'Battle Result: Good triumphs over Evil'
Completed in 1ms
Evil wins
expected 'Battle Result: No victor on this batt…' to equal 'Battle Result: Evil eradicates all tr…'
Read the description again. Not all races have the same worth.
good_vs_evil('0 1 0 0 0 0', '1 0 0 0 0 0 0') what?
expected: 'Battle Result: Good triumphs over Evil'
but got: 'Battle Result: No victor on this battle field'
If you mean your code passing all sample tests and failing tests on Attempt, then yes, it's possible. Your code doesn't use the race worth at all. Read the description again.
Is it possible for the function to pass all the tests and give me the green light, then when I click Attempt it says tests failed?
Obviously a whitespace parsing issue on my end. Thank you, brotha man.
Because I've seen your code, print the input, the one you say your code is failing has this input:
And you wrongly read that as this after some process:
For example, if there are more than 7 numbers in the evil parameter, do I only use the first 7 of the parameter array?
Also, you just changed your reply from saying my numbers were not equal to saying something about single digits?
Are you using [1, 2, 2, 2, 3, 5, 10] for the evil worth values?
GOOD AMOUNT [ '1', '3', '2', '1', '9', '6' ] = 112 && EVIL AMOUNT [ '7', '6', '1', '6', '8', '3', '4'] = 112
TEST EXPECTS: 'Battle Result: Good triumphs over Evil'
This reads a tie but expects good to win?
True! Thanks, I don't know how did I cont last time...
But come on,
1 0 1 1 1 1 1
is 23! And seriously,0 1 1 1 1 1 1
is 24 not 23!Case: good: 1 1 1 1 1 1 evil: 1 0 1 1 1 1 1. Come on! Is 23 === 22!!!
Case: good: 1 1 1 1 1 1 evil: 0 1 1 1 1 1 1. Seriously? Evil wins? 23 bigger than 23???
Because you don't use each race worth properly, read the description again. Not a kata issue.
Loading more items...