with open('celcius.dat', 'r') as fIn, open('fahrenheit.dat', 'w') as fOut:
for line in fIn:
fahrenheit = 9.0 / 5.0 * float(line) + 32
fOut.write("%.1f\\" % fahrenheit)
You can control the number of decimals in the formatting clause in the write statement.