# Convert Celsius to Fahrenheit Whats next?

Convert Celsius to Fahrenheit Whats next?
0

#1

Tell us what’s happening:

Your code so far

``````function convertToF(celsius) {
var fahrenheit;
// Only change code below this line
var celsius = (celsius/1.8)+ 32;

return celsius;
// Only change code above this line
return fahrenheit;
}

// Change the inputs below to test your code

convertToF(30);
``````

Your browser information:

Your Browser User Agent is: `Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/61.0.3163.100 Safari/537.36`.

Link to the challenge:

#2

The above is not the formula for converting Celsius to Fahrenheit. Also, you should be assigning the formula to the fahrenheit variable instead of the celsius variable. Get rid of return celsius;

#3

var fahrenheit = (celsius * 9/5) + 32;
this is it

#4

how to fix these tasks
convertToF(0) should return a number
convertToF(-30) should return a value of -22
convertToF(-10) should return a value of 14
convertToF(0) should return a value of 32
convertToF(20) should return a value of 68
convertToF(30) should return a value of 86
???

#5

You do not need the var on the front.

#6

I have no idea, how to fix this!

#7

Please read my original reply to your topic. You are not doing the very last thing I said.

#8

Sorry, I didn’t understand.

#9

Delete return celsius;

Since you want to return the fahrenheit variable, you do not want to return celsius.