Intermediate
R
Q49 / 100
What is "vectorization" in R and why is it preferred over explicit loops?
Correct! Well done.
Incorrect.
The correct answer is B) Vectorized operations apply functions to entire vectors at once using optimized C code internally, generally being faster and more concise than explicit for loops
B
Correct Answer
Vectorized operations apply functions to entire vectors at once using optimized C code internally, generally being faster and more concise than explicit for loops
Explanation
R's vectorized functions operate element-wise on whole vectors using efficient compiled code, avoiding the overhead of interpreted loop iteration.
Progress
49/100