Completed implementation of Time class