来介绍几个好玩的程序,,,

#include <iostream>
using namespace std;
int main()
{
    char a='\a';
    for (;;)
    {
        cout<<a;
    }
    return 0;
}
这个运行以后就会一直发出“嘀嘀”的声音夏天用来驱蚊





#include<stdio.h> 
int main()

    int i = 0;
  
    for(i=0;i<20;i++)
    {
       system("start"); 
    }
    return 0;
}
每次运行都会跳出来小窗口


#include<windows.h>

#include<stdio.h>

#include<time.h>

#include<conio.h>

int main()

{

system("title ");

int x,y;

printf("点击任意键结束");

while(!_kbhit())

{

x=rand()%332+300;

y=rand()%228+300;

SetCursorPos(x,y);

}

return 0 ;

}
这个是让鼠标乱抖 按任意键结束


#include<windows.h>

#include<stdio.h>

#include<time.h>

#include<conio.h>

int main()

{

system("title ");

int x,y;

printf("按任意键结束");

while(!_kbhit())

{

x=1;

y=1;

SetCursorPos(x,y);

}

return 0 ;

}
这个是鼠标失灵,按任意键结束❀