Java Boolean And and(boolean... bools)

Here you can find the source of and(boolean... bools)

Description

An and gate

License

Open Source License

Parameter

Parameter Description
bools Input

Return

Output

Declaration

public static boolean and(boolean... bools) 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

public class Main {
    /**/*from  www .j av a  2 s. co  m*/
     * An and gate
     * @param bools Input
     * @return Output
     */
    public static boolean and(boolean... bools) {
        boolean total = true;
        for (boolean bool : bools)
            total = total && bool;
        return total;
    }
}

Related

  1. and(boolean a, boolean b)
  2. and(boolean b1, boolean b2)
  3. and(boolean val1, boolean val2)
  4. and(boolean... bs)
  5. and(Boolean... operands)
  6. andBoolOperand(Boolean o, Boolean a)