This section contains a brief introduction to the C language. It is intended as a tutorial on the language, and aims at getting a reader new to C started as quickly as possible. It is certainly not intended as a substitute for any of the numerous textbooks on C. 2. write a recursive function FIB (n) to find out the nth element in theFibanocci sequence number which is 1,1,2,3,5,8,13,21,34,55,…3. write the prefix and postfix form of the following infix expressiona + b – c / d + e * f – g * h / i ^ j4. write a function to count the number of nodes in a binary tr
標簽:
introduction
the
contains
intended
上傳時間:
2013-12-23
上傳用戶:liansi
問題描述
序列Z=<B,C,D,B>是序列X=<A,B,C,B,D,A,B>的子序列,相應的遞增下標序列為<2,3,5,7>。
一般地,給定一個序列X=<x1,x2,…,xm>,則另一個序列Z=<z1,z2,…,zk>是X的子序列,是指存在一個嚴格遞增的下標序列〈i1,i2,…,ik〉使得對于所有j=1,2,…,k使Z中第j個元素zj與X中第ij個元素相同。
給定2個序列X和Y,當另一序列Z既是X的子序列又是Y的子序列時,稱Z是序列X和Y的公共子序列。
你的任務是:給定2個序列X、Y,求X和Y的最長公共子序列Z。
標簽:
lt
序列
上傳時間:
2014-01-25
上傳用戶:netwolf