Skip to main content
Journey Uncommon Logo
JourneyUncommon
mediumRustFrom and Into conversionsSingle-choice MCQ

You implement `From<Celsius> for Fahrenheit`. What does the standard library give you for free, and which direction does it cover?

struct Celsius(f64); struct Fahrenheit(f64); impl From<Celsius> for Fahrenheit { fn from(c: Celsius) -> Self { Fahrenheit(c.0 * 9.0/5.0 + 32.0) } }