結果

問題 No.182 新規性の虜
ユーザー suppy193suppy193
提出日時 2015-05-27 13:05:07
言語 C90
(gcc 11.4.0)
結果
TLE  
(最新)
AC  
(最初)
実行時間 -
コード長 369 bytes
コンパイル時間 416 ms
コンパイル使用メモリ 24,400 KB
実行使用メモリ 6,460 KB
最終ジャッジ日時 2023-08-27 07:18:54
合計ジャッジ時間 22,783 ms
ジャッジサーバーID
(参考情報)
judge13 / judge12
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 1 ms
4,376 KB
testcase_01 AC 1 ms
4,376 KB
testcase_02 AC 1 ms
4,376 KB
testcase_03 AC 1 ms
4,376 KB
testcase_04 AC 1 ms
4,376 KB
testcase_05 AC 0 ms
4,380 KB
testcase_06 AC 0 ms
4,380 KB
testcase_07 AC 1 ms
4,376 KB
testcase_08 AC 1,706 ms
4,376 KB
testcase_09 AC 4,625 ms
4,380 KB
testcase_10 AC 3,407 ms
4,376 KB
testcase_11 AC 2,288 ms
4,376 KB
testcase_12 AC 422 ms
4,376 KB
testcase_13 AC 1 ms
4,380 KB
testcase_14 AC 1 ms
4,376 KB
testcase_15 AC 1 ms
4,376 KB
testcase_16 AC 1 ms
4,380 KB
testcase_17 AC 1 ms
4,380 KB
testcase_18 AC 770 ms
4,376 KB
testcase_19 AC 512 ms
4,376 KB
testcase_20 AC 259 ms
4,376 KB
testcase_21 AC 916 ms
4,380 KB
testcase_22 AC 371 ms
4,376 KB
testcase_23 AC 1 ms
4,380 KB
testcase_24 TLE -
testcase_25 -- -
testcase_26 -- -
testcase_27 -- -
evil01.txt -- -
evil02.txt -- -
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <stdio.h>

int main(void)
{
	int i, j, N, A[100000], num, a;
	scanf("%d", &N);
	for(i = 0;i < N;i++){
		scanf("%d", &A[i]);
	}
	for(i = 0;i < N - 1;i++){
		a = A[i];
		if(a == 0)continue;
		for(j = i + 1;j < N;j++){
			if(a == A[j]){
				A[j] = 0;
				A[i] = 0;
			}	
		}
		if(A[i] != 0)num++;
	}
	if(A[N - 1] != 0)num++;
	
	printf("%d\n", num);
	
	return 0;
}
0