Shiva Wrote in message:
> OK,
> Hi Dave,
>
> I modified it as below and it works(If there is a way to make this more
> efficient please let me know)
>
Deends on what you mean by efficiency.
The big memory efficiency gain was when you got rid of either the
read or readlines.
Performance
OK,
Hi Dave,
I modified it as below and it works(If there is a way to make this more
efficient please let me know)
By the way I am using Python 3.4
import sys
import re
def extract_names(filename):
path = '/home/LearnPython/exercises/'
fullfilename = path+filename
print('fullfilenam