1 条题解

  • 0
    @ 2024-9-25 14:31:16
    #include <iostream>
    #include <iomanip> // 用于设置输出格式
    
    using namespace std;
    
    int main() {
        int c;
        cin >> c; // 读取摄氏温度
    
        // 计算华氏温度
        double f = (9.0 / 5.0) * c + 32;
    
        // 输出华氏温度,保留两位小数
        cout << fixed << setprecision(2) << f << endl;
    
        return 0;
    }
    
    
    • 1

    信息

    ID
    219
    时间
    1000ms
    内存
    16MiB
    难度
    2
    标签
    递交数
    37
    已通过
    10
    上传者