2010年7月30日 星期五

高中 d051: 糟糕,我發燒了!



想看題目請點我

#include <iostream>
#include <iomanip>  //格式控制
using namespace std;
int main() {
    double F, C;
    while( cin >> F )
    { 
       C = ( F - 32 ) * 5 / 9;
       cout << fixed << setprecision(3) << C << endl;
       //fixed 控制「小數點後的位數嗎」
       //setprecision(輸出位數) 
    }
    return 0;
}