import java.lang.*;
import java.util.*;
import java.math.*;
class Brainly{
public static void main(String[] args){
int m, n;
Scanner sc = new Scanner(System.in);
System.out.print("Enter m: "); m = sc.nextInt();
System.out.print("Enter n: "); n = sc.nextInt();
int A[][] = new int[m][n];
for(int i = 0; i < m; i++){
for(int j = 0; j < n; j++){
float random = (float) Math.random();
random *= -100;
int rand = (int) Math.ceil(random) + 200;;
if((i + j) == rand){
System.out.println("A: " + i + " " + j);
};
};
};
};
}