Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- n = int(input())
- if (0 <= n):
- if n == 86400:
- print('0:00:00')
- else:
- if n > 86400:
- while n >= 86400:
- n = (n - 86400)
- if n < 86400:
- h = n // 3600
- m = ((n % 3600) // 60)
- if (m < 10):
- m = ('0' + str(m))
- s = ((n % 3600) % 60)
- if (s < 10):
- s = ('0' + str(s))
- print(str(h) + ':' + str(m) + ':'+ str(s))
- else:
- h = n // 3600
- m = ((n % 3600) // 60)
- if (m < 10):
- m = ('0' + str(m))
- s = ((n % 3600) % 60)
- if (s < 10):
- s = ('0' + str(s))
- print(str(h) + ':' + str(m) + ':' + str(s))
- else:
- not print
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement