logical Operators - Java
Submissions: 7400   Accuracy:

49.1%

  Difficulty: Easy   Marks: 2

Logical operators are used when we want to check the truth value of certain statements. Logical operators help us in checking multiple statements together for their truthness.

Here we will learn logical operators like AND(&&), OR(||), NOT(!). These operators produce either a true or a false as an output.

Input Format:
First line of input conatins number of testcases T. For each testcase, there will be one line of input containing a and b separated by a space.

Output Format:
For each testcase, print the required output.

User Task:
Your task is to complete the provided function logicOp().

Constraints:
1 <= T <= 10
a, b, -> {true, false}

Input:
1
true false

Output:
false true false

** For More Input/Output Examples Use 'Expected Output' option **

Author: Dhiman Mayank


If you have purchased any course from GeeksforGeeks then please ask your doubt on course discussion forum. You will get quick replies from GFG Moderators there.



Need help with your code? Please use ide.geeksforgeeks.org, generate link and share the link here.


to report an issue on this page.