提交 d188b132 创建 作者: 宋海霞's avatar 宋海霞

modify

上级 4a3428cb
...@@ -15,10 +15,10 @@ int main(int argc, char* argv[]) ...@@ -15,10 +15,10 @@ int main(int argc, char* argv[])
List.Elements[i] = i; List.Elements[i] = i;
// //
// 在第 i 个元素之后插入元素 // Insert the element after the ith element
// //
InsertAfter(&List, 33, 5); InsertAfter(&List, 33, 5);
InsertAfter(&List, 45, 15); // 插入位置非法.插入失败. InsertAfter(&List, 45, 15); // Invalid insert position. Insert failed.
for(i=0; i<List.nLength; i++) for(i=0; i<List.nLength; i++)
{ {
...@@ -31,16 +31,16 @@ int main(int argc, char* argv[]) ...@@ -31,16 +31,16 @@ int main(int argc, char* argv[])
/* /*
function: function:
在第 i 个元素之后插入一个元素. Insert an element after the ith element.
parameter: parameter:
pList -- Linear table pList -- Linear table
Elem -- 插入的元素 Elem -- Inserted element
i -- 指定位置.从 1 开始计数. i -- The specified location.Count from 1.
returned value: returned value:
如果插入成功返回 1 Returns 1 if insert succeeds
如果插入失败返回 0 Returns 0 if insert fails
*/ */
int InsertAfter(SqList* pList, ElemType Elem, int i) int InsertAfter(SqList* pList, ElemType Elem, int i)
{ {
......
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论