top1编程
← 返回题目
题解

【入门】成绩(score)

1 条题解

  • 0
    @ 2026-7-29 0:15:40
    #include <iostream>
    using namespace std;
    
    int main() {
        int A, B, C;
        cin >> A >> B >> C;
    
        // 总成绩 = (2*A + 3*B + 5*C) / 10
        int total = (2 * A + 3 * B + 5 * C) / 10;
    
        cout << total << endl;
    
        return 0;
    }
    
    • 1