結果
問題 |
No.143 豆
|
ユーザー |
![]() |
提出日時 | 2018-03-30 14:09:26 |
言語 | C90 (gcc 12.3.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 220 bytes |
コンパイル時間 | 151 ms |
コンパイル使用メモリ | 19,968 KB |
実行使用メモリ | 6,948 KB |
最終ジャッジ日時 | 2024-06-26 00:28:10 |
合計ジャッジ時間 | 868 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 14 WA * 3 |
コンパイルメッセージ
main.c: In function ‘main’: main.c:8:9: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 8 | scanf("%d %d %d",&k, &n, &f); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ main.c:11:17: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 11 | scanf("%d", &a); | ^~~~~~~~~~~~~~~
ソースコード
#include <stdio.h> int main(void) { // your code goes here int k, n, f, a, sum=0; int i; scanf("%d %d %d",&k, &n, &f); for(i=0;i<f;i++){ scanf("%d", &a); sum+=a; } printf("%d", k*n-sum); return 0; }