【初心者歓迎】C/C++室 Ver.9【環境依存OK】
■ このスレッドは過去ログ倉庫に格納されています
0172デフォルトの名無しさん
NGNGusing namespace std;
float CalcTemp( float );
int main()
{
float tempCel;
float tempFahr;
tempFahr = CalcTemp( tempCel );
cout << "Enter celcius Temperature ==> ";
cin >> tempCel;
cout << tempCel << " Celcius Degree = " << tempFahr << " Degree Fahrenheit ";
return 0;
}
float CalcTemp(float tempCel)
{
return 9/5 * tempCel + 32 ;
}
■ このスレッドは過去ログ倉庫に格納されています