Answer Posted / Anamika Choudhary
Control statements in R allow for conditional execution of code and looping through data. They include:n1. If-else: Executes code based on a condition.n2. For: Loops through a sequence of numbers.n3. While: Loops as long as a condition is true.n4. Repeat: Continuously executes a block of code until a specific condition is met.n5. Switch: Performs different actions based on the value of an expression.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers