function listContainsCard(list, cardName) {
        for (var i = 0; i < list.length; i++) {
          if (list[i]['n'] === cardName) {
            return i;
          }
        }
        return -1;
      }
// Returns the index of the card, if found, or -1 otherwise
Returns the index of the card, if found, or -1 otherwise
Returns the index of the card if found or - 1 otherwise
function listContainsCard(list, cardName) {
        for (var i = 0; i < list.length; i++) {
          if (list[i]['n'] === cardName) {
            return i;
          }
        }
        return -1;
      }
function listContainsCard ( list , cardName ) { for ( var i = 0 ; i < list . length ; i ++ ) { if ( list [ i ] [ 'n' ] === cardName ) { return i ; } } return - 1 ; }
Returns the index of the card, if found, or -1 otherwise
Returns the index of the card if found or - 1 otherwise