Feb-20-2019, 08:35 AM
(This post was last modified: Feb-20-2019, 08:35 AM by Shameendra.)
Hi guys, I have a text file which contains the following value:
Output:('Yellow_Hat_Person', [293, 997, [...]], [328, 1031, [...]])
('Yellow_Hat_Person', [292, 998, [...]], [326, 1032, [...]])
('Yellow_Hat_Person', [290, 997, [...]], [324, 1030, [...]])
('Yellow_Hat_Person', [288, 997, [...]], [321, 1028, [...]])
('Yellow_Hat_Person', [286, 995, [...]], [319, 1026, [...]])
I want to write each line into separate text files and save them with a different names. eg. line 1 should be passed to a text file and it should be saved as 1.txt, line to should be passed to a different text file and it should be saves ad 2.txt, line 3 passed to a different text file and saved as 3.txt and so on. Any suggestions would be helpful.