Q. What will be output for the following code?
Code:
str = ""Hello Ruby!"" putc str
β
Correct Answer: (B)
H
Explanation: The output of the following code is just the character H.The putc statement can be used to output one character at a time.