I have a relatively large data file, which I removed from a point marking machine, however it comes as follows:
00003000527005792012635570932000219305130720170713
00003000527005792012635570932000219305130720170713
I would like to separate this data into columns so that I can export to Excel:
00003000527005792 - numero de serie do relógio | 012635570932 - Numero do PIS | 000219305 - NSR |13 - dia | 07 - Mês | 2017 - Ano |07 - hora |13 - minuto
Looking like this:
00003000527005792 012635570932 000219305 13 07 2017 07 13
Well, so far I've been able to read the data using this code:
arquivo = open('DATA.txt', 'r')
for linha in arquivo:
print(linha)
arquivo.close()
How can I apply slice
to this context? Well I can do this in one sentence, but I do not know how to apply it in several lines