import time
date = time.strftime("%d:%m:%y")
print date #returns '18:05:14'
print date[-2:] #returns '14'
print date[:2] #returns '18'
#print ??? <-returns '05'
How can I (preferably) use the [:number:] thing to look for the 4th and 5th character ONLY of "18:05:14" (05)? if i can't use [:#], that's fine. I can't find any possible way, but any help is appreciated.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With