//Write a function to convert celsius to fahrenheit
#include <stdio.h>
float convertTemp(float(celsius));
int main(){
int n;
printf("Enter celsius temperature : ");
scanf("%d ",&n);
float far=convertTemp(n);
printf("\nfar : %.0f ",far);
return 0;
}
float convertTemp(float celsius){
float far = celsius * (9.0/5.0) + 32;
return far;
}
To embed this project on your website, copy the following code and paste it into your website's HTML: