import math d=[] with open("099_exp.txt") as f: for i,line in enumerate(f): a,b=map(int,line.split(",")) d.append([b*math.log(a),i]) print max(d)[1]+1