记录编号 86451 评测结果 AAAAAAAAAA
题目名称 [NOIP 2006]明明的随机数 最终得分 100
用户昵称 Gravatar传奇 是否通过 通过
代码语言 Pascal 运行时间 0.037 s
提交时间 2014-01-26 11:20:39 内存使用 0.15 MiB
显示代码纯文本
program mingming;
var
   tong:array[1..1000] of longint;
   n,i,x,geshu:longint;
begin
   assign(input,'random.in');
   assign(output,'random.out');
   reset(input);
   rewrite(output);

   readln(n);
   for i:=1 to n do
     begin
	   read(x);
	   if tong[x]=0 then
	    begin
	     inc(geshu);
	     inc(tong[x]);
		end;
     end;

   writeln(geshu);
   for i:=1 to 1000 do
    if tong[i]<>0 then
     write(i,' ');
    writeln;	

   close(input);
   close(output);
end.