Question 1 of 25
Hints left: 3
Q1
What is the purpose of the Time.now method in Ruby?
Q2
What does the strftime method do in Ruby when applied to a Time object?
Q3
What does the utc_offset method return for a Time object in Ruby?
Q4
What does the gem outdated command do in Ruby?
Q5
Which method is used to calculate the difference in years between two Date objects in Ruby?
Q6
What does the to_date method do when applied to a Time object in Ruby?
Q7
Which method is used to check if a Time object occurs after another Time object in Ruby?
Q8
How do you find the day of the week for a given Date object in Ruby?
Q9
What does the zone method return for a Time object in Ruby?
Q10
What is the purpose of the --no-ri and --no-rdoc flags when installing gems using Bundler?
Q11
What is the purpose of the zone method for a DateTime object in Ruby?
Q12
What does the gem search -r keyword command do in Ruby?
Q13
Which command is used to list all gems installed on the system in Ruby?
Q14
Which method is used to subtract a number of days from a Date object in Ruby?
Q15
Which method is used to add a number of months to a Date object in Ruby?
Q16
What is the purpose of the strptime method in Ruby?
Q17
How do you create a new Date object representing the current date in Ruby?
Q18
How do you find the difference in seconds between two Time objects in Ruby?
Q19
What does the month method return for a Date object in Ruby?
Q20
How do you find the number of months between two Date objects in Ruby?
Q21
What is the purpose of the gem uninstall gem_name -I command in Ruby?
Q22
How do you convert a Time object to the local time zone in Ruby?
Q23
How do you convert a Date object to a string in Ruby?
Q24
How do you find the number of seconds since the Unix epoch for a Time object in Ruby?
Q25
Which method is used to find the number of days between two Date objects in Ruby?