亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? gexfglxt1.cpp

?? 暑假做的個人消費管理系統
?? CPP
?? 第 1 頁 / 共 2 頁
字號:
#include <malloc.h>
#include <stdio.h>
#include <stdlib.h>
#define LEN sizeof(struct scorenode)
#define DEBUG
#include <string.h>
struct scorenode
{int number;
char name[10];
float living;
float study;
float other;
struct scorenode *next;
};
typedef struct scorenode score;
int n,k;

score *creat2311(void)

{
 score*head;
 score *p1,*p2,*p3,*max;
 int i,j;
 float fen;
    char t[10];
  n=0;
     p1=p2=p3=(score *)malloc(LEN);head=p3; 
       printf("please input the school number!\n");
repeat1: printf("    please input the school number(should up to zero):");
       scanf("%d",&p1->number);
     while(p1->number<0)
   {getchar();
    printf("    wrong input please input again:");
       scanf("%d",&p1->number);}       

  if(p1->number==0)
   goto end;
  else 
  { 
  p3=head;
  if(n>0)
   {for(i=0;i<n;i++)
           {if(p1->number!=p3->number)
     p3=p3->next;
     else 
     {printf("    school number has existed!\n");
     goto repeat1;
     
        }
    }     
   }          
  }
       printf("    please input your name:");
       scanf("%s",&p1->name);
       printf("    input your living fee(should up to zero):");
       scanf("%f",&p1->living);
    while(p1->living<0)
 {getchar();
  printf("    wrong input please input again");
            scanf("%f",&p1->living);}
       printf("    please input the studying fee(should up to zero):");
       scanf("%f",&p1->study);
    while(p1->study<0)
 {getchar();
  printf("    wrong input please input the studing consuming");
           scanf("%f",&p1->study);}
       printf("    input the other fee up to zero:");
       scanf("%f",&p1->other);
    while(p1->other<0)
 {getchar();
  printf("    wrong input input again");
            scanf("%f",&p1->other);}
     head=NULL;
 while(p1->number!=0)
  {
    n=n+1;
 if(n==1)  
  head=p1;
 else
 
    p2->next=p1;
    p2=p1;
    p1=(score *)malloc(LEN);
    printf("    input your data!\n");
repeat2:printf("    input your credit number(should up to zero):");
      scanf("%d",&p1->number);
   
   while(p1->number<0)
   {getchar();
    printf("    wrong number please input again:");
       scanf("%d",&p1->number);}      
  
  if(p1->number==0)
   goto end;
  else
  {
  p3=head;
  if(n>0)
   {for(i=0;i<n;i++)
      {if(p1->number!=p3->number)
    p3=p3->next;
    else 
    {printf("    number has exist repeat again!\n");
     goto repeat2;
    
    }
    }     
   }          
 
  }
  printf("    input your name here:");
       scanf("%s",&p1->name);
     printf("    please input your life consumption(大于0):");
       scanf("%f",&p1->living);
     while(p1->living<0)
  {getchar();
   printf("    wrong input please input again");
         scanf("%f",&p1->living);}
     printf("    please input the studing fee(up to zero):");
      scanf("%f",&p1->study);
     while(p1->study<0)
  {getchar();
   printf("    wrong input please input again");
         scanf("%f",&p1->study);}
      printf("    please input other fee(up to zero):");
       scanf("%f",&p1->other);
     while(p1->other<0)
  {getchar();
   printf("    wrong input please input again");
         scanf("%f",&p1->other);}
     
 }

end: p1=head;
     p3=p1;
  for(i=1;i<n;i++)
               {
             for(j=i+1;j<=n;j++)
                 {
       max=p1;
       p1=p1->next;
      
       if(max->number>p1->number)
        {
        k=max->number;
        max->number=p1->number;
        p1->number=k;
         
        
        strcpy(t,max->name);
        strcpy(max->name,p1->name);
        strcpy(p1->name,t);
     
        fen=max->living;
        max->living=p1->living;
        p1->living=fen;
                 
      
        fen=max->study;
        max->study=p1->study;
        p1->study=fen;
    
       
        fen=max->other;
        max->other=p1->other;
        p1->other=fen;
                
        }

                 }
    max=head;p1=head;
  } 
p2->next=NULL;
       printf("    the number of the person is:%d個!\n",n);
       return(head);

}
  


score *load2311(score *head)

{       score *p1,*p2;
        int m=0;
        char filepn[10];
  FILE *fp;
  
  printf("    please input the name and the course of the file:");
     scanf("%s",filepn);
     if((fp=fopen(filepn,"r+"))==NULL)
 {
  printf("    can not open the file!\n");
  return 0;
 }
     fscanf(fp,"\t\t\t\tpersonal consuming system\n");
     fscanf(fp,"        作者: 潘浩亮 學號:0716000227  班級 :2  專業:計算機科學與技術  \n");
        fscanf(fp,"-----------------------------------------\n");
       
  fscanf(fp,"|number\t|name\t|life fee\t|studing fee\t|other fee\t|\n");
        fscanf(fp,"-----------------------------------------\n");
printf("\t\t\t\tpersonal consuming system\n");
 printf("      作者: 潘浩亮 學號:0716000227  班級 :2  專業:計算機科學與技術  \n");
        printf("    -----------------------------------------\n");
  printf("    |number\t|name\t|life fee\t|studing fee\t|other fee\t|\n");
        printf("    -----------------------------------------\n");
  m=m+1;  
  if(m==1)
  {
  
  p1=(score *)malloc(LEN); 
  fscanf(fp,"%d%s%f%f%f",&p1->number,p1->name,&p1->living,&p1->study,&p1->other);
         printf("    |%d\t|%s\t|%.1f\t|%.1f\t|%.1f\t|\n",p1->number,p1->name,p1->living,p1->study,p1->other);
    
  head=NULL;
     do
  {
   n=n+1;
   if(n==1) head=p1;
   else p2->next=p1;
   p2=p1;
   p1=(score *)malloc(LEN);      
      fscanf(fp,"%d%s%f%f%f\n",&p1->number,p1->name,&p1->living,&p1->study,&p1->other);
            printf("    |%d\t|%s\t|%.1f\t|%.1f\t|%.1f\t|\n",p1->number,p1->name,p1->living,p1->study,p1->other);
           
  }while(!feof(fp));
  p2->next=p1;
  p1->next=NULL;
  n=n+1; 
 }printf("    -----------------------------------------\n");
  fclose(fp);
      
 return (head);
}

   


score *add2311(score *head,score *stu)

{
 score *p0,*p1,*p2,*p3,*max;
    int i,j;
 float fen;
    char t[10];

   p3=stu=(score *)malloc(LEN);\
   printf("    \n    please inpt the data of the person!");
  repeat4: printf("    please input his number(should up to zero):");
  scanf("%d",&stu->number); 
 
      while(stu->number<0)
   {getchar();
    printf("    wrong input please input again:");
       scanf("%d",&stu->number);}
     /******************************************************/
    if(stu->number==0)
   goto end2;
  else 
  { 
   p3=head;
  if(n>0)
   {for(i=0;i<n;i++)
           {if(stu->number!=p3->number)
     p3=p3->next;
     else 
     {printf("    number has existed please input again!\n");
     goto repeat4;
     
        }
    }     
   }          

  }
   
  /******************************************************/  
  printf("    please input the name:");
       scanf("%s",&stu->name);
     printf("    please input the life fee(should up to zero):");
       scanf("%f",&stu->living);
     while(stu->living<0)
  {getchar();
   printf("   wrong input please input again");
         scanf("%f",&stu->living);}
     printf("    please input the studying again(should up to zero):");
      scanf("%f",&stu->study);
     while(stu->study<0)
  {getchar();
   printf("    wrong input please input again");
         scanf("%f",&stu->study);}
      printf("    please input other fee(should up to zero):");
       scanf("%f",&stu->other);
     while(stu->other<0)
  {getchar();
   printf("    wrong input please input again");
         scanf("%f",&stu->other);}
p1=head;
p0=stu;
if(head==NULL)
 {head=p0;p0->next=NULL;}
 else
 {
  if(p1->next==NULL)
  {
   p1->next=p0;
      p0->next=NULL;
  }
     else
  {
    while(p1->next!=NULL)
    {
     p2=p1;p1=p1->next;
    }
        p1->next=p0;
        p0->next=NULL;
  }

 }
 n=n+1;


p1=head;
p0=stu;
  for(i=1;i<n;i++)
               {
             for(j=i+1;j<=n;j++)
                 {
       max=p1;
       p1=p1->next;
      
       if(max->number>p1->number)
        {
        k=max->number;
        max->number=p1->number;
        p1->number=k;
        
        
        strcpy(t,max->name);
        strcpy(max->name,p1->name);
        strcpy(p1->name,t);
     
        fen=max->living;
        max->living=p1->living;
        p1->living=fen;
             
      
        fen=max->study;
        max->study=p1->study;
        p1->study=fen;
  
       
        fen=max->other;
        max->other=p1->other;
        p1->other=fen;
              
        }

                 }
    max=head;p1=head;
  } end2:
 printf("    now the number of person is:%d個!\n",n);
  return(head);

}
 


score *search2311(score *head)

{int number;
 score *p1,*p2;
 printf("    please input the number of the person you want,");
 scanf("%d",&number);

while(number!=0)
{
   if(head==NULL)
  {printf(" \n    no any data!\n");return(head);}

   printf("    -----------------------------------------\n");
   printf("    |number\t|name\t|life fee\t|studing fee\t|other fee\t|\n");
   printf("    -----------------------------------------\n");
   p1=head;
     while(number!=p1->number&&p1->next!=NULL)

  {p2=p1;p1=p1->next;} 
         if(number==p1->number)  
    {printf("    |%d\t|%s\t|%.1f\t|%.1f\t|%.1f\t|\n",p1->number,p1->name,p1->living,p1->study,p1->other);
          printf("    -----------------------------------------\n");}
         else 
           printf("    %d no this person!\n",number);
  
         printf("    input number of the person you want,");
         scanf("%d",&number);
}
printf("    has quited!\n");
return(head);}




score *del2311(score *head)
{
 score *p1,*p2;
int number;
 printf("    input the number of the person you want to delete(zero is quitted):");
 scanf("%d",&number);
 getchar();
 while(number!=0)
 {
 
  if(head==NULL)
  {
   printf("    \n    no data!\n");
   return(head);
  }

  
  p1=head;
  
  while(number!=p1->number&&p1->next!=NULL)
   
  {
   p2=p1;p1=p1->next;
  } 
     
  if(number==p1->number)  
  
  {
   if(p1==head)
    head=p1->next;
  
   else 
      p2->next=p1->next;
  
   printf("    delete:%d\n",number);n=n-1;
  }
  else
   printf("    %dno such person!\n",number);

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
经典三级在线一区| 6080国产精品一区二区| 91美女蜜桃在线| 欧美一级高清片在线观看| 国产精品久久久久久亚洲伦| 亚洲成a人片在线观看中文| 国产精品一二三在| 国产精品原创巨作av| 国产真实乱偷精品视频免| 国产一区二区在线影院| 国产精品18久久久久久久久久久久 | 蜜臂av日日欢夜夜爽一区| 五月婷婷综合激情| 国产成人精品影视| 国产成人一区在线| 亚洲精品成人在线| 美女看a上一区| 欧美高清激情brazzers| 一区二区三区在线观看欧美| 91小视频免费观看| 欧美制服丝袜第一页| 欧美一区三区四区| 久久久99精品免费观看不卡| 国产精品毛片大码女人 | 成人av小说网| 欧洲一区二区三区在线| 日韩欧美国产精品一区| 国产视频一区二区在线| 亚洲欧美日韩国产另类专区| 午夜激情一区二区三区| 国产精品白丝jk黑袜喷水| 色综合久久88色综合天天免费| 欧美高清视频不卡网| 国产亚洲欧美一区在线观看| 亚洲午夜久久久久中文字幕久| 奇米精品一区二区三区在线观看一| 国产一区二区三区免费| 在线观看成人免费视频| www国产成人| 亚洲一区av在线| 国产麻豆精品在线观看| 欧美日韩精品专区| 亚洲成人激情自拍| 99精品久久免费看蜜臀剧情介绍| 日韩在线播放一区二区| 欧美三级中文字| 欧美aaa在线| 日本韩国欧美在线| 久久久不卡网国产精品二区| 亚洲香蕉伊在人在线观| 懂色av一区二区三区蜜臀| 欧美一级黄色录像| 夜夜精品视频一区二区| 国产福利精品导航| 日韩天堂在线观看| 亚洲综合一二区| 99精品视频中文字幕| 久久一留热品黄| 日本不卡的三区四区五区| 色噜噜偷拍精品综合在线| 国产日韩欧美电影| 秋霞国产午夜精品免费视频 | 亚洲自拍与偷拍| 国产成人免费视频| 久久久一区二区三区| 日韩和的一区二区| 欧洲精品在线观看| 依依成人精品视频| 91免费观看在线| 国产精品美日韩| 成人动漫在线一区| 国产精品久久久久影院亚瑟 | 成人免费一区二区三区视频| 国产一区二区美女诱惑| 日韩一级大片在线| 日韩二区三区四区| 欧美日韩黄视频| 日韩电影在线一区| 日韩视频一区在线观看| 奇米一区二区三区| 亚洲精品在线一区二区| 国产在线精品免费av| wwww国产精品欧美| 国产精品1024久久| 中文字幕一区二区三中文字幕| av毛片久久久久**hd| 亚洲婷婷综合久久一本伊一区 | 男人的天堂亚洲一区| 67194成人在线观看| 裸体健美xxxx欧美裸体表演| 精品久久久久久久一区二区蜜臀| 久久机这里只有精品| 久久免费国产精品| 9l国产精品久久久久麻豆| 一区二区三区精品| 日韩亚洲欧美成人一区| 韩国三级电影一区二区| 136国产福利精品导航| 欧美亚一区二区| 久久精品国产99| 国产精品久久午夜夜伦鲁鲁| 在线亚洲一区观看| 久久国产成人午夜av影院| 中文字幕高清一区| 欧美日韩中文另类| 国产高清在线观看免费不卡| 亚洲精选在线视频| 欧美白人最猛性xxxxx69交| 成人性视频免费网站| 日韩精品一区第一页| 国产日韩成人精品| 欧美另类久久久品| 福利电影一区二区| 午夜影院久久久| 国产精品色在线| 日韩三级.com| 91老司机福利 在线| 久久国产精品区| 亚洲日本va在线观看| 欧美刺激脚交jootjob| 色哟哟国产精品免费观看| 久久精品99久久久| 亚洲午夜av在线| 国产精品大尺度| 久久夜色精品国产噜噜av| 欧美三级视频在线观看| jlzzjlzz亚洲女人18| 理论片日本一区| 久久精品人人做| 综合久久国产九一剧情麻豆| 亚洲人成网站在线| 亚洲成人久久影院| 在线观看视频一区二区欧美日韩| 加勒比av一区二区| 日韩国产欧美在线视频| 亚洲视频 欧洲视频| 国产欧美一区二区精品秋霞影院| 91精品在线观看入口| 日本大香伊一区二区三区| 国v精品久久久网| 韩国理伦片一区二区三区在线播放 | 精品少妇一区二区三区免费观看| 日本伦理一区二区| 99精品视频在线观看免费| 精品一区二区三区欧美| 日本va欧美va欧美va精品| 亚洲第一搞黄网站| 亚洲综合丝袜美腿| 一区二区三区中文免费| 亚洲人成在线播放网站岛国| 成人欧美一区二区三区白人| 国产网红主播福利一区二区| 久久―日本道色综合久久| 日韩精品专区在线影院观看| 欧美精品v国产精品v日韩精品| 在线观看不卡视频| 欧美日韩一区二区三区在线看| 色一情一伦一子一伦一区| 色综合一个色综合| 欧美自拍丝袜亚洲| 欧美日韩一级视频| 在线播放一区二区三区| 91精品国产综合久久福利软件| 欧美日韩一区二区不卡| 欧美日韩综合不卡| 日韩免费一区二区| 日本一区二区免费在线| 亚洲欧美怡红院| 亚洲自拍与偷拍| 久久机这里只有精品| 国产高清视频一区| 99久久综合狠狠综合久久| 在线亚洲一区二区| 91精品国产综合久久福利软件| 日韩三级在线免费观看| 国产欧美日韩在线视频| 亚洲美女精品一区| 日韩精品电影在线| 亚洲图片另类小说| 日韩福利电影在线观看| 91激情五月电影| 亚洲欧洲国产日韩| 成人在线一区二区三区| 精品国产一区二区在线观看| 亚洲福利一二三区| 性欧美疯狂xxxxbbbb| 亚洲成人av资源| 国产99精品视频| 欧美性三三影院| 久久久国产精品麻豆| 亚洲成人自拍一区| 国产激情视频一区二区在线观看 | 在线观看一区二区精品视频| 日韩午夜激情免费电影| 中文字幕亚洲一区二区av在线 | 国产精品日产欧美久久久久| 国产伦精一区二区三区| 在线看国产一区二区| 欧美v亚洲v综合ⅴ国产v| 亚洲你懂的在线视频|