Open main menu

CDOT Wiki β

Changes

OPS435 Python3 Lab 7

6 bytes added, 17:32, 5 November 2019
Part 1 - Classes and Methods for our Time objects
self_sec = self.time_to_sec()
t2_sec = t2.time_to_sec()
sum = sec_to_time(sec1 self_sec + sec2t2_sec)
return sum
time_seconds = self.time_to_sec()
nt = sec_to_time(time_seconds + seconds)
timeself.hour, timeself.minute, timeself.second = nt.hour, nt.minute, nt.second
return None
1,760
edits