I have been tasked with building a simple Ruby app that does two things:
Registers new users with a New command Shows their time difference with Work command
It would be for an office building and the purpose would be to keep track of total hours worked.
I am also supposed to pull this information from a .txt file like so:
New Aaron
New Bertha
New Charles
Work Bertha 06:30 11:12
Work Bertha 12:03 16:17
Work Charles 07:52 17:02
With the time expressed in only minutes and hours. I don't think anyone would be working past midnight. This is the part that really confuses me, as I am having a lot of trouble trying to find the difference in their times for work, as shown in an expected output .txt file:
Aaron: 0 hours 0 minutes
Bertha: 8 hours 52 minutes
Charles: 9 hours 10 minutes
Once again, I am ONLY asking for help with finding the difference in each individual's time for work.
Any and all help would be appreciated.