比赛 NOIP_1 评测结果 AWTTTTTTTA
题目名称 圆弦 最终得分 20
用户昵称 NickName 运行时间 0.000 s
代码语言 Pascal 内存使用 0.00 MiB
提交时间 2008-09-03 22:03:09
显示代码纯文本
program circlex2;
var x1,x2:longint;
ci,co:text;
n:longint;
jg:longint;
procedure go(a,b:longint);
var x:longint;
begin
jg:=jg+1;
if b+1<n then for x:=b+2 to n do go(b+1,x);
if a+1<b-1 then for x:=a+2 to b-1 do go(a+1,x);
end;
begin
assign(ci,'circlex.in');
reset(ci);
readln(ci,n);
close(ci);
jg:=1;
for x1:=1 to n-1 do
for x2:=x1+1 to n do go(x1,x2);
assign(co,'circlex.out');
rewrite(co);
writeln(co,jg);
close(co);
end.