πŸ“Š Ruby
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
πŸ’¬ Discuss
βœ… Correct Answer: (D) IO.readlines

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

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

πŸ’¬ Discussion


πŸ“Š Question Analytics

πŸ‘οΈ
207
Total Visits
πŸ“½οΈ
3 y ago
Published
πŸŽ–οΈ
Mr. Dubey
Publisher
πŸ“ˆ
85%
Success Rate