Ask Question
17 March, 10:28

Write a program in c language which takes 5 inputs from the user. The inputs are

temperature in Celsius scale. The program computes the

corresponding Fahrenheit scale and displays as two columns

+3
Answers (1)
  1. 17 March, 12:34
    0
    double CelciusToFahrenheit (double celcius)

    {

    return celcius * 1.8 + 32;

    }

    int main ()

    {

    double celcius[5];

    int i;

    for (i = 0; i < 5; i++)

    {

    printf ("Enter temperature %d in Celcius: ", i+1);

    scanf_s ("%lf", &celcius[i]);

    }

    for (i = 0; i < 5; i++)

    {

    printf ("%2.1lf/t%2.1lf/n", celcius[i], CelciusToFahrenheit (celcius[i]));

    }

    }
Know the Answer?
Not Sure About the Answer?
Get an answer to your question ✅ “Write a program in c language which takes 5 inputs from the user. The inputs are temperature in Celsius scale. The program computes the ...” in 📙 Computers & Technology if there is no answer or all answers are wrong, use a search bar and try to find the answer among similar questions.
Search for Other Answers