• <ins id="pjuwb"></ins>
    <blockquote id="pjuwb"><pre id="pjuwb"></pre></blockquote>
    <noscript id="pjuwb"></noscript>
          <sup id="pjuwb"><pre id="pjuwb"></pre></sup>
            <dd id="pjuwb"></dd>
            <abbr id="pjuwb"></abbr>
            心如止水
            Je n'ai pas le temps
            posts - 400,comments - 130,trackbacks - 0
            #include<stdio.h>
            #include
            <stdlib.h>
            struct node
            {
                   
            int data;
                   
            struct node *next;
            }
            ;//結(jié)構(gòu)類型的說明

            struct node *stack(struct node *head)
            {
                 
            int i;
                 
            struct node *p;
                 p 
            = (struct node*)malloc(sizeof(struct node));
                 p
            ->next = NULL;
                 
            for(i=0;i<10;i++)
                   
            {
                     head 
            = (struct node*)malloc(sizeof(struct node));
                     p
            ->data = i;
                     head
            ->next = p;
                     p 
            = head;;
                   }

                 
            return (head);
            }
            //

            struct node *team(struct node *head)
            {
                 
            int i;
                 
            struct node *tail,*p;
                 head 
            = (struct node*)malloc(sizeof(struct node));
                 tail 
            = head;
                 
            for(i=0;i<10;i++)
                   
            {
                     p 
            = (struct node*)malloc(sizeof(struct node));
                     p
            ->data = i;
                     tail
            ->next = p;
                     tail 
            = p;
                   }

                 tail
            ->next = NULL;
                 
            return (head);
            }
            //隊(duì)列

            void print_list(struct node *head)
            {
                 
            struct node *p;
                 p 
            = head->next;
                 printf(
            "Begin");
                 
            while(p != NULL)
                   
            {
                     printf(
            "->%d",p->data);
                     p 
            = p->next;
                   }

                 printf(
            "->End\n");
            }
            //鏈表輸出

            void detele_x(struct node *head,int x)
            {
                 
            struct node *p,*q;
                 p 
            = head;
                 q 
            = head->next;
                 
            while(q->data != x && q->next != NULL)
                   
            { p = q; q = q->next; }
                 
            if(q->data == x)
                   p
            ->next = q->next;
                 free(q);
            }
            //刪除數(shù)據(jù)域?yàn)閤的結(jié)點(diǎn)

            void add_x_y(struct node *head,int x,int y)
            {
                 
            struct node *add_new,*p,*q;
                 add_new 
            = (struct node*)malloc(sizeof(struct node));
                 add_new
            ->data = x;
                 p 
            = head;
                 q 
            = head->next;
                 
            while(q != NULL && q->data != y)
                   
            { p = q; q = q->next; }
                 p
            ->next = add_new;
                 add_new
            ->next = q;
            }
            //在數(shù)據(jù)為y的結(jié)點(diǎn)前插入數(shù)據(jù)域?yàn)閤的結(jié)點(diǎn)
            posted on 2010-01-06 18:22 lee1r 閱讀(220) 評論(0)  編輯 收藏 引用 所屬分類: 算法與數(shù)據(jù)結(jié)構(gòu)
            久久亚洲AV无码西西人体| 人妻精品久久久久中文字幕69| 成人a毛片久久免费播放| 色综合久久综精品| 日本国产精品久久| 午夜欧美精品久久久久久久| 国内精品九九久久久精品| 国产综合免费精品久久久| 精产国品久久一二三产区区别 | 久久婷婷五月综合国产尤物app| 久久精品国产亚洲AV电影| 欧美粉嫩小泬久久久久久久| 亚洲乱码中文字幕久久孕妇黑人| 青草影院天堂男人久久| 久久精品国产乱子伦| 久久精品成人免费观看97| 久久精品国产亚洲AV无码麻豆| 狠狠精品久久久无码中文字幕| 久久午夜伦鲁片免费无码| 亚洲国产高清精品线久久| 99久久精品国产一区二区三区| 97久久婷婷五月综合色d啪蜜芽 | 亚洲国产精品一区二区久久hs| 国产精品99久久久久久www| 久久av无码专区亚洲av桃花岛| 中文成人无码精品久久久不卡 | 色妞色综合久久夜夜| 亚洲国产精品嫩草影院久久| 99久久精品无码一区二区毛片| 久久精品国产亚洲av高清漫画| 亚洲日本久久久午夜精品| 狠狠精品久久久无码中文字幕 | 久久精品国产亚洲αv忘忧草| 久久综合成人网| 久久久精品久久久久久| 99久久伊人精品综合观看| 九九99精品久久久久久| 国产精品一区二区久久精品| 久久综合狠狠综合久久| 精品久久久久久中文字幕| 日本免费久久久久久久网站|