[C] 终止程序运行 →→→→→进入此内容的聊天室

来自 , 2019-08-23, 写在 C, 查看 114 次.
URL http://www.code666.cn/view/01894d6f
  1. #include <stdlib.h>
  2. #include <conio.h>
  3. #include <stdio.h>
  4.  
  5. int main ( void )
  6. {
  7.         int status;
  8.  
  9.         printf ( "Enter either 1 or 2\n" );
  10.         status = getch();
  11.         /* Sets DOS errorlevel  */
  12.         exit ( status - '0' );
  13.  
  14.         /* Note: this line is never reached */
  15.         return 0;
  16. }

回复 "终止程序运行"

这儿你可以回复上面这条便签

captcha