Wanted an easy way to extract year month and day from a string. Using Python 3.1.2
Tried this:
processdate = "20100818"
print(processdate[0:4])
print(processdate[4:2])
print(processdate[6:2])
Results in:
...2010
...
...
Reread all the string docs, did some searching, can't figure out why it'd be doing this. I'm sure this is a no brainer that I'm missing somehow, I've just banged my head on this enough today.