Ad
  • Custom User Avatar

    This is not a proper way to report a bug in a kata.

    If you want to report a bug, you need to:

    • Tell what language you are attempting,
    • Show your formatted code,
    • Show what input causes problems, and why you think it's not handled by tests correctly.

    Your solution not passing tests is not a kata issue.

  • Custom User Avatar

    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…'

  • Custom User Avatar

    Read the description again. Not all races have the same worth.

  • Default User Avatar

    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'

  • Custom User Avatar

    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.

  • Default User Avatar

    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?

  • Custom User Avatar

    Obviously a whitespace parsing issue on my end. Thank you, brotha man.

  • Custom User Avatar

    Because I've seen your code, print the input, the one you say your code is failing has this input:

    ("132 196 432 622 929 373", "761 683 48 801 805 463 176"),
    

    And you wrongly read that as this after some process:

    ("1 3 2 1 9 6", "7 6 1 6 8 3 4"),
    
  • Custom User Avatar

    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?

  • Custom User Avatar

    Are you using [1, 2, 2, 2, 3, 5, 10] for the evil worth values?

  • Custom User Avatar

    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?

  • Custom User Avatar

    True! Thanks, I don't know how did I cont last time...

  • Custom User Avatar

    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!

  • Custom User Avatar

    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???

  • Custom User Avatar

    Because you don't use each race worth properly, read the description again. Not a kata issue.

  • Loading more items...