import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; /* * To change this template, choose Tools | Templates * and open the template in the editor. */ import java.util.ArrayList; /** * * @author cteam29 */ public class ith { /** * @param args the command line arguments */ public static void main(String[] args) throws IOException { BufferedReader reader = new BufferedReader(new InputStreamReader(System.in)); String line; while(!( line = reader.readLine()).equals("0 0 0")){ String[] l= line.split(" "); int a = Integer.valueOf(l[0]); int b = Integer.valueOf(l[1]); boolean[][] arr = new boolean[a][b]; int number = Integer.valueOf(l[2]); for(int i=0; i= 0 && q.j +i < b){ // arr[q.i-i][q.j+i] = true; // } // if(q.i+i < a && q.j -i >= 0){ // arr[q.i+i][q.j-i] = true; // } // if(q.i-i >= 0 && q.j -i >=0){ // arr[q.i-i][q.j-i] = true; // } // } } int sum = 0; for(int i = 0; i < radek.length; i++){ for(int j = 0; j< sloup.length; j++){ if(!radek[i]&& !sloup[j] && !diagL[i + j] && !diagR[i - j+a] ){ sum++; } } } // int sum = 0; // for(int i = 0; i queens = new ArrayList(); public static class Queen{ public int i; public int j; public Queen(int i, int j) { this.i = i; this.j = j; } } }