Q. How do you create a loop that prints the squares of numbers from 1 to 10 in R?
β
Correct Answer: (A)
for (i in 1:10) { print(i^2) }
You must be Logged in to update hint/solution