Which loop in R is used when the number of iterations is known beforehand?
a) while loop
b) repeat loop
c) for loop
d) do-while loop
Answer:
c) for loop
Explanation:
The for loop is used in R when the number of iterations is known before the loop starts.