class Board {

    public String paint(int width, int height) {
        StringBuilder screen = new StringBuilder();
        String ln = System.lineSeparator();
        for (int currentHeight = 0; currentHeight < height; currentHeight++) {
            for (int currentWidth = 0; currentWidth < width; currentWidth++) {
                if ((currentWidth + currentHeight) % 2 == 0) {
                    screen.append("x");
                } else {
                    screen.append(" ");
                }
            }
            screen.append(ln);
        }
        return screen.toString();
    }

}