/************************************************
Grundlegende Algorithmen mit Java,
http://algorithmen-und-problemloesungen.de/
Copyright @2007-2008 by Doina Logofatu
************************************************/

import java.io.*;
import java.util.*;

public class P03Knight {
  private static final String FileInputName = "springer.in";
  private static final String FileOutputName = "springer.out";
  private static final int dx[] = { -2, -2, -1, -1, 1, 1, 2, 2 };
  private static final int dy[] = { -1, 1, -2, 2, -2, 2, -1, 1 };

  private static boolean onTheTable(int x, int y, int m, int n) {
    return (0 <= x && x < m) && (0 <= y && y < n);
  }

  private static int nrAllowedSteps(int a[][], 
                  int m, int n, int x, int y) {
    int nr = 0;
    int xn, yn;
    for (int i = 0; i < 8; i++) {
      xn = x + dx[i];
      yn = y + dy[i];
      if (onTheTable(xn, yn, m, n) && a[xn][yn] == 0)
        nr++;
    }
    return nr;
  }

  static boolean findBestSucc(int a[][], int m, int n, int xy[]) {
    int aux = Integer.MAX_VALUE;
    int xn, yn, xx = 0, yy = 0;
    for (int i = 0; i < 8; i++) {
      xn = xy[0] + dx[i];
      yn = xy[1] + dy[i];
      if (onTheTable(xn, yn, m, n) && a[xn][yn] == 0) {
        int steps = nrAllowedSteps(a, m, n, xn, yn);
        if (steps < aux){
          aux = steps;
          xx = xn;
          yy = yn;
        }
      }
    }
    if (aux < Integer.MAX_VALUE) {
      xy[0] = xx;
      xy[1] = yy;
      return true;
    }
    return false;
  }

  public static void main(String[] args) throws IOException {
    Scanner scanner = null;
    PrintStream out = null;
    try {
      scanner = new Scanner(new File(FileInputName));
      out = new PrintStream(new File(FileOutputName));

      int m = scanner.nextInt();
      int n = scanner.nextInt();
      int l = scanner.nextInt();
      int c = scanner.nextInt();
      l--;
      c--;
      int[][] a = new int[m][n];

      a[l][c] = 1;
      int ctr = 1;
      int xy[] = new int[2];
      xy[0] = l;
      xy[1] = c;
      while (findBestSucc(a, m, n, xy)) {
        a[xy[0]][xy[1]] = ++ctr;
      }
      if (ctr == m * n) {
        for (int i = 0; i < m; i++) {
          for (int j = 0; j < n; j++) {
            out.printf("%4d ", a[i][j]);
          }
          out.println();
        }
      } else {
        out.println("Keine Loesung!");
      }
    } finally {
      if (scanner != null) {
        scanner.close();
      }
      if (out != null) {
        out.close();
      }
    }
  }
}

