完全不会啊……附一份题解:http://blog.sina.com.cn/s/blog_69c3f0410100tyjl.html 1 var i,j,k,r,c,x:longint; 2 ch:array[0..10100,0..80] of char; 3 s:string; 4... Read More
又2b了一次…… 1 var s:ansistring; 2 ans,pre:array[0..10000] of longint; 3 i,k,tot:longint; 4 procedure main; 5 begin 6 pre[1]:=0;k:=0; 7 for i:=... Read More
脑残wa了一次 1 var s:ansistring; 2 ans,i,k,m:longint; 3 pre:array[0..1010000] of longint; 4 function max(x,y:longint):longint; 5 begin 6 if x>... Read More
var x,y:array[0..110000] of string; i,n,l,r,mid:longint; s:string;procedure qsort(h,l:longint); var i,j:longint; temp,m:string; begin i:=h;j... Read More
读入建立一棵字母树,并且每到一个节点就增加这个节点的覆盖数。然后再重新扫一遍,一旦碰到某个覆盖数为1就是这个单词的最短前缀了。不知为何下面的程序一直有bug……不知是读入的问题?type node=record w:longint; go:array['a'..'z'] of lon... Read More