python - How to convert a time string to seconds? - Stack Overflow

PHOTO EMBED

Wed Dec 02 2020 22:18:17 GMT+0000 (Coordinated Universal Time)

Saved by @AboSari #python

time = "01:34:11"
sum(x * int(t) for x, t in zip([3600, 60, 1], time.split(":"))) 
content_copyCOPY

https://stackoverflow.com/questions/10663720/how-to-convert-a-time-string-to-seconds