/***************************************************************************** * kelvin.c * Matthew Chartier * CS 50/CSCI E-52 * Fall 2010 * * Converts Fahrenheit to Kelvin. *****************************************************************************/ #include #include int main(int argc, char *argv[]) { //Get fahrenheit temp from user float fahr; printf("Fahrenheit temp: "); fahr = GetFloat(); float kelvin = (fahr - 32) * (5.0 / 9.0) + 273; printf("Kelvin Conversion: %5.2f\n", kelvin); // print more if conversion is less than absolute zero if(kelvin < 0) printf("That doesn't make any sense!\n"); }