When I execute the program and I enter C or F and complete the process, this is the image of what I see:
I want to hide the line in the red rectangle. This is the code I have:
#include <stdio.h>
int main(void){
float f,c;
char var;
int x;
while(var!='x'){
printf("x=Ende c=Umrechnung c->f f=Umrechnung f->c:");
scanf("%c",&var);
if(var=='c'){
printf("Grad Celsius =");
scanf("%f",&c);
f=(c*1.8)+32;
printf("%.2f Grad Celsius sind %.2f Grad Fahrenheit\n",c,f);
}
else if(var=='f'){
printf("Grad Fahrenheit =");
scanf("%f",&f);
c=(f-32)/1.8;
printf("%.2f Grad Fahrenheit sind %.2f Grad Celsius\n",f,c);
}
else if(var=='x'){
printf("fertig !! chao\n");
}
else {
printf("Ungiltige Umreechnungsart!!\n");
}
}
return 0;
}