with open(sys.argv[2]) as f:
processlist = f.readlines()
for a in range(0,1):
process = processlist[a]
print process
for b in range(0,3):
process1 = process.split()
print process1[b]
sys.argy[2 ] files just has 2 sentences
Sunday Monday
local owner public
I am trying to read once sentence at a time and in each sentence I am trying to access one word at a time.... I am able to get the things i need individually but the loop doesn’t not iterate... it stops after first iteration....