Which Of The Following R Code Generate A Sequence Of Integers #339
Which of the following R code generate a sequence of integers from 1 to 10?
This multiple choice question (MCQ) is related to the book/course gs gs110 R Language. It can also be found in gs gs110 Control Structures, Functions, Scoping Rules, Loop Functions and Debugging - Control Structures - Quiz No.1.
Which of the following R code generate a sequence of integers from 1 to 10?
> for(i in 1:9) { + print(i) + } [1]
> for(i in 0:9) { + print(i) + } [1]
> for(i in 1:10) { + print(i) + } [1]
> for(i in 2:50) { + print("i") + } [1]