Tagged: Controls

elseif

elseif IF statement condition. elseif is used with IF. The statements after the elseif are executed if the expression is true and all the preceding IF and elseif expressions are false. An expression is...

if

if if statement condition. The general form of the if statement is if expression statements ELSEIF expression statements ELSE statements END The statements are executed if the real part of the expression has all...

for

for Repeat statements a specific number of times. The general form of a for statement is: for variable = expr, statement, …, statement END The columns of the expression are stored one at a...

end

end Terminate scope of FOR, WHILE, SWITCH, TRY, and IF statements. Without END’s, FOR, WHILE, SWITCH, TRY, and IF wait for further input. Each end is paired with the closest previous unpaired FOR, WHILE,...

else

else Used with IF. else is used with IF. The statements after the else are executed if all the preceding IF and ELSEIF expressions are false. The general form of the IF statement is...

continue

continue Pass control to the next iteration of FOR or WHILE loop. continue passes control to the next iteration of FOR or WHILE loop in which it appears, skipping any remaining statements in the...

case

Matlab Case Switch Statement case SWITCH statement case. case is part of the SWITCH statement syntax, whose general form is: SWITCH switch_expr case case_expr, statement, …, statement case {case_expr1, case_expr2, case_expr3,…} statement, …, statement...