code: public static boolean and(final INDArray n, final Condition cond) {
          if (cond instanceof BaseCondition) {
              long val = (long) Nd4j.getExecutioner().exec(new MatchCondition(n, cond)).getDouble(0);
  
              if (val == n.length())
                  return true;
              else
                  return false;
  
          } else {
              throw new RuntimeException("Can only execute BaseCondition conditions using this method");
          }
      }
docs: And over the whole ndarray given some condition
  
  @param n    the ndarray to test
  @param cond the condition to test against
  @return true if all of the elements meet the specified
  condition false otherwise