当前位置:编程学习 > C/C++ >>

数据结构---线性表


测试代码
TestList.c
[cpp]
#include <stdio.h> 
#include "List.h" 
 
int main() 

    int a = 0; 
    ElemType Elem; 
    SeqList list; 
    initList(&list); 
    for(; a<25; a++) 
    { 
        listAppend(&list, a); 
    } 
    showListInfo(&list); 
    if(getElem(&list, 20, &Elem)) 
        printf("%d",Elem); 
    listInsert(&list, 23, 2323); 
    listInsert(&list, 23, 2323); 
    listInsert(&list, 23, 2323); 
//    listInsert(&list, 23, 2323); 
//    listInsert(&list, 23, 2323); 
// 
    showList(&list); 
    reverseList(&list); 
    showList(&list); 

补充:软件开发 , C++ ,
CopyRight © 2022 站长资源库 编程知识问答 zzzyk.com All Rights Reserved
部分文章来自网络,