Ad
  • Custom User Avatar
  • Custom User Avatar

    Yep, as @Voile said: there are much more performing ways to handle it :+1:

  • Custom User Avatar

    Maybe you'd want to look up this problem. There is indeed a much more efficient way to deal with it.

  • Custom User Avatar

    Hi @tiaho47,

    the inital code is set up as

    function Game(board){
      // This is where you define all of your class variables
    }
    
    Game.prototype.play = function(){
      // This is a function of the class "Game". All the tests cases take the value returned from this function to check if it is correct
      
      return correctValue
    }
    

    So Game is the name of the class and play is a function of the class Game. You just need to return the correct value from the play function for the tests to pass.

    Just to let you know, this kata is fairly hard (I personally think it should be a 4KYU) so you may want to try easier katas before attempting this one :-)

    Hope this helps?