Having trouble with a Python Project - Functions


#1

Hey all,

I’m having a lot of trouble getting through a task from a project. This is what it is:

Write a function called f_to_c that takes an input f_temp , a temperature in Fahrenheit, and converts it to c_temp , that temperature in Celsius.

It should then return c_temp .

The equation you should use is:

Temp (C) = (Temp (F) - 32) * 5/9

Any help would be much appreciated.

Thanks!


#2

The corresponding variables are described in the instructions. Insert in the formula as apply.

Remember your math functions?

y = f(x)

Now think of it as,

C = f(F)

where f(F) is,

5 * (F - 32) / 9

Now return it.


#3

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.