結果

問題 No.143 豆
ユーザー shop_one
提出日時 2019-07-25 17:56:57
言語 C++14
(gcc 13.3.0 + boost 1.87.0)
結果
WA  
実行時間 -
コード長 260 bytes
コンパイル時間 559 ms
コンパイル使用メモリ 64,184 KB
実行使用メモリ 6,948 KB
最終ジャッジ日時 2024-07-02 06:15:11
合計ジャッジ時間 3,125 ms
ジャッジサーバーID
(参考情報)
judge4 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 1 WA * 14 RE * 1 TLE * 1
権限があれば一括ダウンロードができます

ソースコード

diff #

#include<iostream>
using namespace std;
int main(){
    int k,n,f,mame;
    cin >> k >> n >> f;
    int a[f];
    mame = k*n;
    for(int i=0;i<n;i++){
        cin >> a[i];
        mame -= a[i];
    }
    if(mame<0)cout <<"-1\n";
    else cout << mame<<endl;
}
0