comefrom: <awangdev>Majority Number II_1.java
code: public int majorityNumber(List<Integer> nums) {
          if (nums == null || nums.size() == 0) {
              return -1;
          }
          int valA = 0; 
          int valB = 0;
          int countA = 0;
          int countB = 0;
          for (int num : nums) {
              if (num == valA) {
                  countA++;
              } else if (num == valB) {
                  countB++;
              } else if (countA == 0) {
                  valA = num;
                  countA++;
              } else if (countB == 0){
                  valB = num;
                  countB++;
              } else {
                  countA--;
                  countB--;
              }
          }
          
          countA = 0; 
          countB = 0;
          for (int num : nums) {
              if (num == valA) {
                  countA++;
              } else if (num == valB) {
                  countB++;
              }
          }
          return countA > countB ? valA : valB;
      }
masked: public int sample_funcname ( List < Integer > var_0 ) {
    if ( var_0 == null || var_0 . size ( ) == 0 ) {
      return - 1 ;
    }
    int var_1 = 0 ;
    int var_2 = 0 ;
    int var_3 = 0 ;
    int var_4 = 0 ;
    for ( int var_5 : var_0 ) {
      if ( var_5 == var_1 ) {
        var_3 ++ ;
      }
      else if ( var_5 == var_2 ) {
        var_4 ++ ;
      }
      else if ( var_3 == 0 ) {
        var_1 = var_5 ;
        var_3 ++ ;
      }
      else if ( var_4 == 0 ) {
        var_2 = var_5 ;
        var_4 ++ ;
      }
      else {
        var_3 -- ;
        var_4 -- ;
      }
    }
    var_3 = 0 ;
    var_4 = 0 ;
    for ( int var_5 : var_0 ) {
      if ( var_5 == var_1 ) {
        var_3 ++ ;
      }
      else if ( var_5 == var_2 ) {
        var_4 ++ ;
      }
    }
    return var_3 > var_4 ? var_1 : var_2 ;
  }
  