• Custom User Avatar

    Indentations were not that messed up when I clicked submit, sorry ^^"

  • Custom User Avatar

    Just checked and random tests did in fact start with the field after the explosions (due to the array being passed as a reference to the sample function which returns the expected result), which could make it easier to cheese this kata. This has now been fixed. What you have to do now is simulate the explosions yourself, and then finding the safe spots.

  • Custom User Avatar

    The kata description states that "The last session in the array cannot end after the cinema closes". The session starting at 2:30 would end after the cinema closes at 3:00, which is why it isn't in the list. Hope this helps!

  • Custom User Avatar

    Added :)

  • Custom User Avatar

    Alright, I think I understood what you meant now ;)
    I computed the expected solution before making the assertion:

    expected = ex_mine_field(field)
    test.assert_equals(safe_mine_field(field), expected)            
    

    Is this correct?

  • Custom User Avatar

    Should be fixed now.

  • Custom User Avatar

    Thank you for the tips and letting me know about the "attackable" array! All of your points should be fixed in the new solution and tests :)

  • Custom User Avatar

    Should be fixed now. What was happening was that, in my solution, the explosive charge of some mines could override any mines it crossed in its path. Thanks for letting me know! Publishing the fixed solution real quick.

  • Custom User Avatar

    I'll look into that in a moment and let you know when it's fixed :)

  • Custom User Avatar

    Added

  • Custom User Avatar

    Fixed, plus added a few random tests testing these edge cases :)

  • Custom User Avatar

    Done. Did not know how to do that, thanks!

  • Custom User Avatar

    Ignore this. It's the sample code and didn't think it'd be posted. Go to the Python solution instead lol

  • Custom User Avatar

    Ignore the JavaScript code, I didn't know that'd be posted lol. I made the tests and sample solution in Python.
    It's my first kata, be merciful please :')

  • Custom User Avatar

    I thought this wouldn't submit, please add the ability to delete own solutions or have an admin delete this for me please. I didn't even come up with this solution, I just wanted to have it removed from my Unfinished list considering I gave up