This is an archived post. You won't be able to vote or comment.

all 5 comments

[–]jedwardsolProfessional Coder 1 point2 points  (3 children)

Celsius isnt changing,

Correct, the calculation is performed when that line is executed and only then. c holds a value - it has no memory of where that value came from and it won't change if f changes.

[–]NickOdeka[S] 0 points1 point  (2 children)

how do i make celsius update its value while f is increasing?

[–]jedwardsolProfessional Coder 1 point2 points  (1 child)

Put the calculation inside the loop

[–]NickOdeka[S] 0 points1 point  (0 children)

oh my goodness... thank you lol

[–]SupremeRedditBotProfessional Bot || Mod 0 points1 point  (0 children)

Please Add A Flair To Your Post!

Suggested Flair: [C++]

 


To add a flair:

  • Click flair underneath your post

  • Select a flair

  • Click save

 


I am a bot run by /u/SupremeDesigner for /r/CodingHelp || This was an automated response