You need to sign in or sign up before continuing.×
Ad
  • Custom User Avatar

    zombies in the 3rd sample test

        [[0,0,18],[2,3,12],[2,5,25],[4,2,21],[6,1,35],[6,4,9],[8,0,22],[8,1,8],[8,2,17],[10,3,18],[11,0,15],[12,4,21]]
    

    Your debug code:

    z = [[0,0,18],[2,3,12],[2,4,25],[4,2,21],[6,1,35],[6,4,9],[8,0,22],[8,1,8],[8,2,17],[10,3,18],[11,0,15],[12,4,21]]
    print(plants_and_zombies(l, z))
    

    Notice that the 3rd item in the array is different ([2,5,25] & [2,4,25]).

    After changing it your code does return 20.

    Not a kata issue.

  • Custom User Avatar

    Just did it on kotlin everything is correct.

  • Custom User Avatar

    This comment is hidden because it contains spoiler information about the solution

  • Custom User Avatar

    This comment is hidden because it contains spoiler information about the solution