主观

下列算法实现求采用顺序结构存储的串S和串t的一个最长公共子串。 void maxcomstr(string*s,*t;int index,length) { int i,j,k,lengthl,con; index=0;length=0;i=1; while(i<=strlen(s)) { j=1; while(j<=strlen(t)) { if(s[i]==t[j] { k=1;lengthl=1;con=1; while(con) if((1)) { lengthl=lengthl+1;k=k+1; } else (2) ; if(lengthl>length) {index=i;length=lengthl;} (3); } else (4); } (5); } }

参考答案
您可能感兴趣的试题
¥

订单号:

遇到问题请联系在线客服

订单号:

遇到问题请联系在线客服