main.c

来自「用C语言实现数据结构的几种常用结构」· C语言 代码 · 共 44 行

C
44
字号
show7()
{int choice;
 printf("\n***********************FUNCTION*********************************\n");
 printf("\t*1.list\n\t*2.string\n\t*3.stack\n\t*4.kmp\n\t*5.sort\n\t*6.path\n\t*7.exit");
 printf("\n***************************************************************\n");
 printf("please make the choice.\n");
 do
  {scanf("%d",&choice);
   if((choice<1)||(choice>7))
   printf("ERROR!please input again.\n");
  }while((choice<1)||(choice>7));
 return(choice);
}
main()
{
 int choice;

  do
  {choice=show7();
   switch(choice)
    {case 1:{LIST();
             break;
             }
     case 2:{str();
             break;
             }
     case 3:{stack();
             break;
             }
     case 4:{kmpt();
             break;
             }
     case 5:{pai();
             break;
             }
     case 6:{gua();
             break;
             }
     case 7:break;
    }
  }while(choice!=7);
}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?