FUNDAMENTALS OF COMPUTER

COMPUTER PROGRAMMING FUNDAMENTALS

WHAT IS PROGRAMMING

Question [CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
Which of the following would be a conditional operation?
A
Wet hair
B
Turn left
C
Rinse
D
Add soap until suds appear
Explanation: 

Detailed explanation-1: -An Example of Conditional Operators The conditional operator “&&” first evaluates whether its first operand (i.e., number % 2 == 0) is true and then evaluates whether its second operand (i.e., number % 4 == 0) is true. As both are true, the logical AND condition is true.

Detailed explanation-2: -The conditional operator (? :) is a ternary operator (it takes three operands).

Detailed explanation-3: -Ternary operator is a Conditional operator in C#. It takes three arguments and evaluates a Boolean expression.

Detailed explanation-4: -The conditional (ternary) operator is the only JavaScript operator that takes three operands: a condition followed by a question mark ( ? ), then an expression to execute if the condition is truthy followed by a colon ( : ), and finally the expression to execute if the condition is falsy.

There is 1 question to complete.