Split single file into multiple files based on patterns
Steven D'Aprano
steve+comp.lang.python at pearwood.info
Wed Oct 24 03:52:06 EDT 2012
On Tue, 23 Oct 2012 20:01:03 -0700, satyam wrote:
> I have a text file like this
>
> A1980JE39300007 2732 4195 12.527000
[...]
> I want to split the file and get multiple files like A1980JE39300007.txt
> and A1980KK18700010.txt, where each file will contain column2, 3 and 4.
Are you just excited and want to tell everyone, or do you actually have a
question?
Have you tried to write some code, or do you just expect others to do
your work for you?
If so, I see that your expectation was correct.
--
Steven
More information about the Python-list
mailing list