In Ruby, what is the keyword used to define a method?
A. function
B. define
C. method
D. def
Answer: Option D
A. function
B. define
C. method
D. def
Answer: Option D
What does the 'puts' method do in Ruby?
A. Prints to console
B. Converts to string
C. Finds the length
D. Reads input from user
Join The Discussion