結果

問題 No.143 豆
ユーザー rinrinta121
提出日時 2019-03-31 12:11:23
言語 C++14
(gcc 13.3.0 + boost 1.87.0)
結果
WA  
実行時間 -
コード長 344 bytes
コンパイル時間 606 ms
コンパイル使用メモリ 65,664 KB
実行使用メモリ 5,248 KB
最終ジャッジ日時 2024-11-21 11:00:36
合計ジャッジ時間 1,264 ms
ジャッジサーバーID
(参考情報)
judge2 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 16 WA * 1
権限があれば一括ダウンロードができます

ソースコード

diff #

#include<iostream>
#include<vector>
using namespace std;
typedef long long ll;

int main()
{
    int k,n,f;
    cin >> k >> n >> f;
    int a[f];
    int been = k * n;
    for(int i = 0; i < f; i++){
        cin >> a[i];
        been -= a[i];
    }
    if(been > 0){
        cout << been << endl;
    }else{
        cout << -1 << endl;
    }
}
0