public static void ConsoleConvert(double t, Tcunit from, Tcunit to) { double res = Convert(t, from, to); Console.WriteLine(t + @" " + from + @" = " + res + @" " + to); }
public static double Convert(double t, Tcunit from, Tcunit to) { var res = t * _lookup[(int)from] / _lookup[(int)to]; return(res); }