結果
問題 | No.191 供託金 |
ユーザー | Haijinn |
提出日時 | 2017-02-01 22:01:39 |
言語 | C90 (gcc 12.3.0) |
結果 |
AC
|
実行時間 | 1 ms / 5,000 ms |
コード長 | 333 bytes |
コンパイル時間 | 239 ms |
コンパイル使用メモリ | 22,144 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-12-24 02:20:44 |
合計ジャッジ時間 | 1,245 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 23 |
コンパイルメッセージ
main.c: In function ‘main’: main.c:17:1: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 17 | scanf("%d",&n); | ^~~~~~~~~~~~~~ main.c:19:9: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 19 | scanf("%d",&c[i]); | ^~~~~~~~~~~~~~~~~
ソースコード
#include <stdio.h> #include<stdlib.h> int main(void) { int n; int a[100]; int b[100]; int c[100]; int i; int q[100]; int f; int d; int j=0; int k=0; int r=0; int x=0; scanf("%d",&n); for(i=0;i<n;i++){ scanf("%d",&c[i]); j+=c[i]; } for(i=0;i<n;i++){ if(c[i]<=0.1*j){ x++; } } printf("%d\n",x*30); return 0; }