1 条题解

  • 0
    @ 2025-11-30 16:24:19

    C++ :

    #include <iostream>
    using namespace std;
    int main() {
        int currency;
        double amount;
        cin >> currency >> amount;
        switch (currency) {
            case 1: cout << "转换后的金额: " << amount * 7 << " 人民币"; break;
            case 2: cout << "转换后的金额: " << amount / 7 << " 美元"; break;
            default: cout << "无效的选择";
        }
        return 0;
    }
    
    • 1

    信息

    ID
    534
    时间
    1000ms
    内存
    128MiB
    难度
    (无)
    标签
    递交数
    0
    已通过
    0
    上传者