Software Engineering Wiki

FahrenheitToCelsius

Converts Fahrenheit to Celsius.

  • Follows the conversion formula C = (F - 32) * 5/9.
func FahrenheitToCelsius(d float64) float64 {
	return (d - 32.0) * 5.0 / 9.0
}
FahrenheitToCelsius(32.0) // 0.0

Last updated 15 September 2026 · Edit this page