比赛 20120706 评测结果 ATTTTTTTTA
题目名称 校草 最终得分 20
用户昵称 zhangchi 运行时间 0.000 s
代码语言 Pascal 内存使用 0.00 MiB
提交时间 2012-07-06 09:50:59
显示代码纯文本
var
  n,i,j,ans:longint;
  a,b,c,d:array[1..100000] of longint;
  p:array[1..100000] of boolean;
begin
  assign(input,'hjjhvf.in'); reset(input);
  assign(output,'hjjhvf.out'); rewrite(output);
  readln(n);
  for i:=1 to n do
    readln(a[i],b[i],c[i],d[i]);
  for i:=1 to n do
    for j:=1 to n do
      begin
        if (a[i]>a[j])and(b[i]>b[j])and(c[i]>c[j]) then begin inc(ans); p[i]:=true; break; end;
        if (a[i]>a[j])and(b[i]>b[j])and(d[i]>d[j]) then begin inc(ans); p[i]:=true; break; end;
        if (a[i]>a[j])and(c[i]>c[j])and(d[i]>d[j]) then begin inc(ans); p[i]:=true; break; end;
        if (b[i]>b[j])and(c[i]>c[j])and(d[i]>d[j]) then begin inc(ans); p[i]:=true; break; end;
      end;
  writeln(ans);
  for i:=1 to n do
    if p[i] then writeln(i);
  close(input); close(output);
end.