COMPUTER FUNDAMENTALS

COMPUTER SOFTWARE

PROGRAMMING LANGUAGES

Question [CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
Then
A
To provide a response if a statement is not met
B
To provide a response if a statement is met
C
A loop with a condition set at the start
D
Used in a question as part of the decision process
Explanation: 

Detailed explanation-1: -To write an if statement, write the keyword if, then inside parentheses () insert a boolean value, and then in curly brackets write the code that should only execute when that value is true . That code is called the body of the if statement.

Detailed explanation-2: -Conditionals (or Selection): which are used to execute one or more statements if a condition is met. Loops (or Iteration): which purpose is to repeat a statement a certain number of times or while a condition is fulfilled.

Detailed explanation-3: -The if-else statement is used to execute both the true part and the false part of a given condition. If the condition is true, the if block code is executed and if the condition is false, the else block code is executed.

Detailed explanation-4: -The part after the “if": you get good grades-is called a hypotheses and the part after the “then”-you will get into a good college-is called a conclusion. Hypotheses followed by a conclusion is called an If-then statement or a conditional statement. This is read-if p then q.

There is 1 question to complete.