Fixed right edge (IndexOutOfBounds)