For example I have this text (Input):
Event Time, Monday:
10:01:02,269 to 10:01:08,702
(Reported by John).
Event Time, Sunday:
20:01:08,931 to 20:01:15,234
(Reported by Peter).
...
Then you want to alter and increase the time (only the time), thus (Output):
Event Time, Monday:
10:01:02,369 to 10:01:09,002 #Change the microseconds and seconds
(Reported by John).
Event Time, Sunday:
20:01:09,131 to 20:01:15,934 #Change the microseconds and seconds
(Reported by Peter).
Once I have the times, I can alter. So the problem is how to get only the times. I was thinking that maybe one way would be to collect the times in a list, like this:
times = ['10:01:02,269', '10:01:08,702', '20:01:08,931', '20:01:15,234']
But how to make that? and then, how to increase it in the list? And finally how to print without changing the text.
'[0-9:,]'
to find all the time data.times.sort()
can increase time in the listprint 'it time %s' % str(times[0])
for instance, could print without changing the text