open file and format readin
fopen = open("filename.txt", "r");
a = [];
b = [];
str = fopen.readline()
a.append(str.split(' ')[0]);
if len(str.split(' ')) > 2:
b.append(str.split(' ')[2])
else:
b.append(str.split(' ')[1])
while ( str != '' ):
print str
str = fopen.readline()
if (str !=''):
a.append(str.split(' ')[0])
if len(str.split(' ')) > 2:
b.append(str.split(' ')[2])
else:
b.append(str.split(' ')[1])