Ruby MCQ set number 00172

1. What is the output of the given code? for num in 1…5 puts num end a) 1 2 3 4 5 b) 1 2 3 4 c) 2 3 4 5 d) None of the mentioned AnswerAnswer: b [Reason:] As the range i.e 1…10 is exclusive the loop will loop till 4 and then…


This content is for paid premium members only.
You can view complete answer after activation your membership.


Need only one answers. Simply buy single day pass and email. We will send answers for this question.
Login Buy membership