A

Admin • 831.35K Points
Coach

Q. Which of the method is used to returns the contents of the file line by line?

  • (A) IO.read
  • (B) IO.foreach
  • (C) IO.syswrite
  • (D) IO.readlines
  • Correct Answer - Option(D)
  • Views: 20
  • Filed under category Ruby
  • Hashtags:

Explanation by: Admin
One of the IO class methods is IO.readlines. This method returns the contents of the file line by line.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.