[C++] IT男专用表白程序 →→→→→进入此内容的聊天室

来自 , 2021-01-25, 写在 C++, 查看 154 次.
URL http://www.code666.cn/view/f26dab9b
  1. #include<iostream.h>
  2. #include<windows.h>
  3. #include<stdio.h>
  4. #define stoptimeshort  40
  5. #define stoptimelong   100
  6. void main()
  7. {
  8.         //////////////////
  9.         char ch[10];
  10.         int f[9][36]={  0,1,1,1,1,1,0,0,0,0,0,0,1,1,0,0,0,0,0,1,1,0,0,0,0,0,1,0,0,0,0,0,0,0,0,1,
  11.                         0,0,0,1,0,0,0,0,0,0,1,0,0,0,0,1,0,1,0,0,0,0,1,0,0,0,1,0,0,0,0,0,0,0,0,1,
  12.                         0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,1,0,0,1,0,0,0,0,0,0,0,0,1,
  13.                         0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,1,0,0,0,0,0,0,0,0,1,
  14.                         0,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,1,0,0,0,0,0,0,0,0,1,
  15.                         0,0,0,1,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,0,0,0,1,0,0,0,0,0,0,0,0,1,
  16.                         0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,1,
  17.                         0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,1,0,1,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,1,0,
  18.                         0,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,0,0,0,0
  19.                      };
  20.         int s[9][21]={  0,0,0,1,1,0,0,0,0,0,1,1,0,0,0,0,1,1,0,0,0,
  21.                         0,1,0,0,0,0,1,0,1,0,0,0,0,1,0,0,0,0,0,1,0,
  22.                         1,0,0,0,0,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,1,
  23.                         1,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,1,
  24.                         0,1,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,1,0,
  25.                         0,0,1,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,1,0,0,
  26.                         0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,
  27.                         0,0,0,0,0,0,1,0,1,0,0,0,1,0,1,0,0,0,0,0,0,
  28.                         0,0,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,0,0,
  29.                      };
  30.         int t[9][22]={  0,0,0,1,1,0,0,0,0,0,0,0,0,0,0,0,0,1,1,0,0,0,
  31.                         0,1,0,0,0,0,1,0,0,0,0,0,0,0,0,1,0,0,0,0,1,0,
  32.                         1,0,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,0,0,1,
  33.                         1,0,0,0,0,0,1,0,0,0,0,1,0,0,0,0,0,0,0,0,0,1,
  34.                         0,1,0,0,0,0,0,1,0,0,0,0,1,0,0,0,0,0,0,0,1,0,
  35.                         0,0,1,0,0,0,0,0,1,0,0,0,0,1,0,0,0,0,0,1,0,0,
  36.                         0,0,0,0,1,0,0,0,0,1,0,0,0,0,1,0,0,1,0,0,0,0,
  37.                         0,0,0,0,0,0,1,0,1,0,0,0,0,0,0,1,1,0,0,0,0,0,
  38.                         0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,1,0,0,0,0,0,0,
  39.                      };
  40.         system ( "title I Love You" );
  41.         //////////////////
  42.         printf ( "%s","        " );
  43.         Sleep ( stoptimelong );
  44.         printf ( "%s","其" );
  45.         Sleep ( stoptimeshort );
  46.         printf ( "%s","实\n" );
  47.         ////////////////////////////////
  48.         printf ( "%s","        " );
  49.         system ( "color 72" );
  50.         Sleep ( stoptimelong );
  51.         printf ( "%s","有" );
  52.         Sleep ( stoptimeshort );
  53.         printf ( "%s","一" );
  54.         Sleep ( stoptimeshort );
  55.         printf ( "%s","句" );
  56.         Sleep ( stoptimeshort );
  57.         printf ( "%s","话\n" );
  58.         ///////////////////////////
  59.         printf ( "%s","        " );
  60.         system ( "color 79" );
  61.         Sleep ( stoptimelong );
  62.         printf ( "%s","一" );
  63.         Sleep ( stoptimeshort );
  64.         printf ( "%s","直" );
  65.         Sleep ( stoptimeshort );
  66.         printf ( "%s","藏" );
  67.         Sleep ( stoptimeshort );
  68.         printf ( "%s","在" );
  69.         Sleep ( stoptimeshort );
  70.         printf ( "%s","我" );
  71.         Sleep ( stoptimeshort );
  72.         printf ( "%s","心" );
  73.         Sleep ( stoptimeshort );
  74.         printf ( "%s","里\n" );
  75.         /////////////////////////////
  76.         printf ( "%s","        " );
  77.         system ( "color 7c" );
  78.         Sleep ( stoptimelong );
  79.         printf ( "%s","可" );
  80.         Sleep ( stoptimeshort );
  81.         printf ( "%s","是\n" );
  82.         ///////////////////////////////
  83.         printf ( "%s","        " );
  84.         system ( "color 7d" );
  85.         Sleep ( stoptimelong );
  86.         printf ( "%s","我" );
  87.         Sleep ( stoptimeshort );
  88.         printf ( "%s","没" );
  89.         Sleep ( stoptimeshort );
  90.         printf ( "%s","有" );
  91.         Sleep ( stoptimeshort );
  92.         printf ( "%s","勇" );
  93.         Sleep ( stoptimeshort );
  94.         printf ( "%s","气" );
  95.         Sleep ( stoptimeshort );
  96.         printf ( "%s","对" );
  97.         Sleep ( stoptimeshort );
  98.         printf ( "%s","你" );
  99.         Sleep ( stoptimeshort );
  100.         printf ( "%s","说\n" );
  101.         ///////////////////////////////
  102.         printf ( "%s","        " );
  103.         system ( "color 7e" );
  104.         Sleep ( stoptimelong );
  105.         printf ( "%s","今" );
  106.         Sleep ( stoptimeshort );
  107.         printf ( "%s","天\n" );
  108.         //////////////////////////////
  109.         printf ( "%s","        " );
  110.         system ( "color 7a" );
  111.         Sleep ( stoptimelong );
  112.         printf ( "%s","我" );
  113.         Sleep ( stoptimeshort );
  114.         printf ( "%s","终" );
  115.         Sleep ( stoptimeshort );
  116.         printf ( "%s","于" );
  117.         Sleep ( stoptimeshort );
  118.         printf ( "%s","鼓" );
  119.         Sleep ( stoptimeshort );
  120.         printf ( "%s","起" );
  121.         Sleep ( stoptimeshort );
  122.         printf ( "%s","勇" );
  123.         Sleep ( stoptimeshort );
  124.         printf ( "%s","气\n" );
  125.         ///////////////////////////////
  126.         printf ( "%s","        " );
  127.         system ( "color 7b" );
  128.         Sleep ( stoptimelong );
  129.         printf ( "%s","我" );
  130.         Sleep ( stoptimeshort );
  131.         printf ( "%s","要" );
  132.         Sleep ( stoptimeshort );
  133.         printf ( "%s","对" );
  134.         Sleep ( stoptimeshort );
  135.         printf ( "%s","你" );
  136.         Sleep ( stoptimeshort );
  137.         printf ( "%s","说:\n" );
  138.         ///////////////////////////////
  139.         printf ( "%s","        " );
  140.         system ( "color 79" );
  141.         Sleep ( stoptimelong );
  142.         printf ( "%s","我" );
  143.         Sleep ( stoptimeshort );
  144.         printf ( "%s","…\n" );
  145.         /////////////////////////////////
  146.         printf ( "%s","        " );
  147.         system ( "color 72" );
  148.         Sleep ( stoptimelong );
  149.         printf ( "%s","我" );
  150.         Sleep ( stoptimeshort );
  151.         printf ( "%s","…" );
  152.         Sleep ( stoptimeshort );
  153.         printf ( "%s","…\n" );
  154.         //////////////////////////////////
  155.         Sleep ( stoptimelong );
  156.         system ( "color fc" );
  157.         for ( int i=0; i<9; i++ )
  158.         {
  159.                 cout<<"        ";
  160.                 for ( int j=0; j<36; j++ )
  161.                 {
  162.                         if ( f[i][j]==0 )
  163.                                 cout<<" ";
  164.                         else
  165.                                 cout<<"*";
  166.                 }
  167.                 cout<<endl;
  168.                 Sleep ( 100 );
  169.         }
  170.         /////////////////////////////////////
  171. line:
  172.         printf ( "%s","        " );
  173.         Sleep ( stoptimelong );
  174.         printf ( "%s","你" );
  175.         Sleep ( stoptimeshort );
  176.         printf ( "%s","愿" );
  177.         Sleep ( stoptimeshort );
  178.         printf ( "%s","意" );
  179.         Sleep ( stoptimeshort );
  180.         printf ( "%s","接" );
  181.         Sleep ( stoptimeshort );
  182.         printf ( "%s","受" );
  183.         Sleep ( stoptimeshort );
  184.         printf ( "%s","我" );
  185.         Sleep ( stoptimeshort );
  186.         printf ( "%s","吗" );
  187.         Sleep ( stoptimeshort );
  188.         printf ( "%s","?(Y/N)" );
  189.         ////////////////////////////////////
  190.         cout<<endl;
  191.         cout<<"        ";
  192.         cin>>ch;
  193.         Sleep ( stoptimelong );
  194.         if ( ch[0]=='y'||ch[0]=='Y' )
  195.         {
  196.                 system ( "color fc" );
  197.                 for ( int i=0; i<9; i++ )
  198.                 {
  199.                         cout<<"        ";
  200.                         for ( int j=0; j<21; j++ )
  201.                         {
  202.                                 if ( s[i][j]==0 )
  203.                                         cout<<" ";
  204.                                 else
  205.                                         cout<<"*";
  206.                         }
  207.                         cout<<endl;
  208.                         Sleep ( 100 );
  209.                 }
  210.                 Sleep ( 3000 );
  211.         }
  212.         else
  213.         {
  214.                 if ( ch[0]=='n'||ch[0]=='N' )
  215.                 {
  216.                         system ( "color 0f" );
  217.                         for ( int i=0; i<9; i++ )
  218.                         {
  219.                                 cout<<"        ";
  220.                                 for ( int j=0; j<22; j++ )
  221.                                 {
  222.                                         if ( t[i][j]==0 )
  223.                                                 cout<<" ";
  224.                                         else
  225.                                                 cout<<"*";
  226.                                 }
  227.                                 cout<<endl;
  228.                                 Sleep ( 100 );
  229.                         }
  230.                         printf ( "%s","        " );
  231.                         Sleep ( stoptimelong );
  232.                         printf ( "%s","心" );
  233.                         Sleep ( stoptimeshort );
  234.                         printf ( "%s","碎" );
  235.                         Sleep ( stoptimeshort );
  236.                         printf ( "%s","了" );
  237.                         Sleep ( stoptimeshort );
  238.                         printf ( "%s","……\n" );
  239.                 }
  240.                 else
  241.                         goto line;
  242.         }
  243.         system ( "color 0f" );
  244.         system ( "pause" );
  245. }

回复 "IT男专用表白程序"

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

captcha