📚 Question Bank Q36 — Programming and Data Structure
Tags
Programming and Data Structure
Q36. Marks: +2.0 UGC NET Paper 2: Computer Science 11 March 2023

Consider the following conditional code, which returns a Boolean values

if ((x > 25) && (y >100))

   return 'false';

else if((x ≤ 25) && (y ≤ 100))

   return 'true';

else if((x > 25) && (y ≤ 100))

      return 'false';

else

   return 'true';

Simplify it by filling in the following blank with a single Boolean expression without changing the behaviour of the conditional code.

if (__________)

    return 'true';

else

    return 'false'; 

1.x > 25
2.x ≤ 25 ✓ Correct
3.y >100 
4.y ≤ 100
📄 All “Programming and Data Structure” questions across papers
🏷 Change Tag for this Question