Q. How do you get the current date and time in Ruby?

  • (A) date = Date.now
  • (B) time = Time.now
  • (C) datetime = DateTime.now
  • (D) now = Date.today
πŸ’¬ Discuss
βœ… Correct Answer: (B) time = Time.now

You must be Logged in to update hint/solution

πŸ’¬ Discussion


πŸ“Š Question Analytics

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