Submission #00375
ソースコード
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 | #include <stdio.h> int main() { int n, cnt, wan, c; int ais[10]; while ( 1 ) { scanf ( "%d" , &n); if ( n == 0 ) return 0; for ( cnt=0; cnt<10; cnt++ ) ais[cnt] = 0; for ( cnt=0; cnt<n; cnt++ ) { scanf ( "%d" , &wan); ais[wan]++; } for ( cnt=0; cnt<10; cnt++ ) { for ( c=0; c<ais[cnt]; c++ ) printf ( "*" ); if ( ais[cnt] <= 0 ) printf ( "-" ); printf ( "\n" ); } } return 0; } |
ステータス
項目 | データ |
---|---|
問題 | 0004 - 人気のアイスクリーム店 |
ユーザー名 | sth1515 |
投稿日時 | 2016-08-29 11:55:34 |
言語 | C |
状態 | Accepted |
得点 | 4 |
ソースコード長 | 434 Byte |
最大実行時間 | 25 ms |
最大メモリ使用量 | 272 KB |
セット
セット | 得点 | Cases | |
---|---|---|---|
1 | ALL | 4 / 4 | * |
テストケース
ファイル名 | 状態 | 実行時間 | メモリ使用量 | # |
---|---|---|---|---|
00.in | AC | 25 ms | 252 KB |
1
|
01.in | AC | 16 ms | 272 KB |
1
|