Sophie

Sophie

distrib > Mandriva > 2008.1 > x86_64 > by-pkgid > 8da85283d75a871d50bb67379a0ceca4 > files > 17

zh-autoconvert-0.3.16-3mdv2008.1.x86_64.rpm

#!/usr/bin/python
#Author Ha Shao <hashao@china.com>
#2000.8.30

import fileinput
import string

for line in fileinput.input():
    if(fileinput.filename() == "400b5.txt"):
    	total = 171894734
    elif (fileinput.filename() == "400gb.txt"):
        total = 45376453

    s = string.split(line)
    print "%s,\t%f" % (s[1], (float(s[2]))/ total * 100)