description: The only difference between this problem and D2 is that you don't have to provide the way to construct the answer in this problem, but you have to do it in D2.
  
  There's a table of n × m cells (n rows and m columns). The value of n ⋅ m is even.
  
  A domino is a figure that consists of two cells having a common side. It may be horizontal (one of the cells is to the right of the other) or vertical (one of the cells is above the other).
  
  You need to find out whether it is possible to place nm/2 dominoes on the table so that exactly k of them are horizontal and all the other dominoes are vertical. The dominoes cannot overlap and must fill the whole table.
  
  Input
  
  The first line contains one integer t (1 ≤ t ≤ 10) — the number of test cases. Then t test cases follow.
  
  Each test case consists of a single line. The line contains three integers n, m, k (1 ≤ n,m ≤ 100, 0 ≤ k ≤ nm/2, n ⋅ m is even) — the number of rows, columns and horizontal dominoes, respectively.
  
  Output
  
  For each test case output "YES", if it is possible to place dominoes in the desired way, or "NO" otherwise.
  
  You may print each letter in any case (YES, yes, Yes will all be recognized as positive answer, NO, no and nO will all be recognized as negative answer).
  
  Example
  
  Input
  
  
  8
  4 4 2
  2 3 0
  3 2 3
  1 2 0
  2 4 2
  5 2 2
  2 17 16
  2 1 1
  
  
  Output
  
  
  YES
  YES
  YES
  NO
  YES
  NO
  YES
  NO
solution: // Don't place your source in a package
  
  
  import javax.swing.*;
  import java.lang.reflect.Array;
  import java.text.DecimalFormat;
  import java.util.*;
  import java.lang.*;
  import java.io.*;
  import java.math.*;
  import java.util.stream.Stream;
  
  
  
  // Please name your class Main
  public class Main {
      static FastScanner fs=new FastScanner();
      static class FastScanner {
          BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
          StringTokenizer st=new StringTokenizer("");
          public String next() {
              while (!st.hasMoreElements())
                  try {
                      st=new StringTokenizer(br.readLine());
                  } catch (IOException e) {
                      e.printStackTrace();
                  }
              return st.nextToken();
          }
          int Int() {
              return Integer.parseInt(next());
          }
  
          long Long() {
              return Long.parseLong(next());
          }
  
          String Str(){
              return next();
          }
      }
  
  
      public static void main (String[] args) throws java.lang.Exception {
          PrintWriter out = new PrintWriter(new BufferedWriter(new OutputStreamWriter(System.out)));
          //reading /writing file
          //Scanner sc=new Scanner(new File("input.txt"));
          //PrintWriter pr=new PrintWriter("output.txt");
  
  
          int T=Int();
          for(int t=0;t<T;t++){
              int n=Int();int m=Int();
              int k=Int();
              Solution sol=new Solution(out);
              sol.solution(n,m,k);
          }
          out.close();
  
      }
  
  
  
  
      public static int[] Arr(int n){
          int A[]=new int[n];
          for(int i=0;i<n;i++)A[i]=Int();
          return A;
      }
      public static int Int(){
          return fs.Int();
      }
      public static long Long(){
          return fs.Long();
      }
      public static String Str(){
          return fs.Str();
      }
  
  }
  
  
  
  
  
  
  
  
  class Solution {
      PrintWriter out;
      int INF = Integer.MAX_VALUE;
      int MOD = 1000000007;
      int mod = MOD;
      public Solution(PrintWriter out) {
          this.out = out;
      }
  
  
  
      char A[]=new char[]{'a','b','c','d'};
      int index=0;
      public void solution(int n,int m,int k) {
          if(n*m%2!=0){
              out.println("NO");
              return;
          }
  
          if(n%2==0){
              if(k%2!=0){
                  out.println("NO");
                  return;
              }
              char res[][]=get1(n,m,k);
              if(res[0][0]=='e'){
                  out.println("NO");
                  return;
              }
              print(res);
              return;
          }
          else{
              k = n*m/2-k;
              if(k%2!=0){
                  out.println("NO");
                  return;
              }
              char res[][]=get1(m,n,k);
              if(res[0][0]=='e'){
                  out.println("NO");
                  return;
              }
  
              char res1[][]=new char[n][m];
              for(int x=0;x<n;x++){
                  for(int y=0;y<m;y++){
                      res1[x][y]=res[y][x];
                  }
              }
  
              print(res1);
              return;
          }
      }
  
      public char[][] get1(int n,int m,int k){
          char res[][]=new char[n][m];
          for(int i=0;i<n;i++){
              for(int j=0;j<m;j++){
                  res[i][j]='e';
              }
          }
  
          for(int c=0;c+1<m;c+=2){
              for(int r=0;r<n;r+=2){
                  if(k==0)break;
                  char c1=get(res,r,c-1);
                  char c2=get(res,r-1,c);
                  char c3=get(res,r+1,c-1);
                  while(A[index]==c1||A[index]==c2||A[index]==c3){
                      index++;
                      index%=4;
                  }
                  res[r][c]=A[index];
                  res[r][c+1]=A[index];
  
                  c1=get(res,r,c);
                  c2=get(res,r+1,c-1);
                  c3=get(res,r+1,c-1);
                  while(A[index]==c1||A[index]==c2||A[index]==c3){
                      index++;
                      index%=4;
                  }
                  res[r+1][c]=A[index];
                  res[r+1][c+1]=A[index];
                  k-=2;
              }
              if(k==0)break;
          }
  
          if(k!=0){
              res[0][0]='e';
              return res;
          }
  
  
          for(int c=0;c<m;c++){
              for(int r=0;r<n;r++){
                  if(res[r][c]!='e')continue;
                  char c1=get(res,r,c-1);
                  char c2=get(res,r-1,c);
                  char c3=get(res,r+1,c-1);
                  while(A[index]==c1||A[index]==c2||A[index]==c3){
                      index++;
                      index%=4;
                  }
                  res[r][c]=A[index];
                  res[r+1][c]=A[index];r++;
              }
          }
          return res;
      }
  
      public char get(char mat[][],int i,int j){
          if(i<0||j<0||i>=mat.length||j>=mat[0].length)return 'e';
          return mat[i][j];
      }
  
      public void print(char mat[][]){
          out.println("YES");
      }
  
  
  
  }
  