English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

2 answers

its just simple math, so you just need to know what they want to convert to (F or C), and what the temp is. you write the program though.

2006-10-25 02:53:19 · answer #1 · answered by justme 7 · 0 0

#include
#include


void main()
{
clrscr();
int choice;
float c,f;

do
{
cout<<"\n\n\tMENU\n";
cout<<"1.Centigrade to Farenhiet\n";
cout<<"2.Farenhiet to Centrigade\n";
cout<<"0.Exit.\n";
cin>>choice;
if(choice==1)
{
cout<<"\nEnter value:";
cin>>c;
f=((9*c)/5)+32;
cout<<"\nFarenheit equivalent:"< }
if(choice==2)
{
cout<<"\nEnter value:";
cin>>f;
c=((f-32)*5)/9;
cout<<"\nCentigrade equivalent:"< }

}while(choice);
}



this was enough to recallmy programming..kidding
just copy this and paste it in a notepad file and save it as a .cpp extn. open file in TC and have fun...

2006-10-25 10:03:25 · answer #2 · answered by naman 2 · 0 1

fedest.com, questions and answers