I want to write a program for this: In a folder I have n number of files; first read one file and perform some operation then store result in a separate file. Then
You may find the fileinput module useful. It is designed for exactly this problem.