Need help asap plz
<p>can someone tell me what i did wrong in my code?</p>

<p>I implemented a method to go through a board that contains 100 cells and check if the cell contains either the String "L10" or "C10". If a matching String is founded Chutes or Ladders would be increment.</p>

<p>this is my method.</p>

<pre><code>public class ChutesAndLadders {

    public int addToMove(String cell) {
        if (cell.equals("L10")) ladders++;
        else if (cell.equals("C10")) chutes++;
        else {
            chutes = chutes;
            ladders = ladders;
        }
        return ladders;
    }

        int chutes = 0, ladders = 0;
        for (String cell: cl.board) {
            int additionalSpaces = cl.addToMove(cell);
            if (additionalSpaces &gt; 0) ladders++;
            else if (additionalSpaces &lt; 0) chutes++;
        }
        System.out.println("Board has " + chutes + " chutes and " + ladders + " ladders");
        cl.printBoard();
    }
}
</code></pre>

<p>Board has 0 chutes and 92 ladders</p>

<pre><code>|   |   |   |C10|   |   |   |   |L10|C10|
|C10|   |   |L10|   |   |   |   |   |   |
|   |   |   |   |   |   |L10|C10|   |C10|
|   |   |   |   |   |   |   |   |   |   |
|   |   |   |   |   |L10|   |   |L10|C10|
|   |L10|   |   |   |   |   |   |   |   |
|   |C10|L10|   |   |L10|   |   |   |   |
|   |   |   |L10|   |   |   |C10|   |   |
|C10|   |   |   |   |   |   |   |C10|L10|
|   |   |   |   |   |   |   |   |   |   |
</code></pre>

<p>That is my output. Somehow i ended up with 92 ladders instead of 10.</p>

<p>Thank You for the Help.</p>
