- 博客(8)
- 收藏
- 关注
原创 lg1067 多项式输出(模拟、字符串)
题目 大笨蛋代码: #include <iostream> #include<stdio.h> #include<stdlib.h> #include<math.h> #include<string> using namespace std; string change(int x) { int j; string k; ...
2020-04-08 02:14:16 188
原创 lg1601高精度加法(同xoj)
题目 #include<iostream> #include<stdio.h> #include<stdlib.h> #include<string> using namespace std; string add(string a,string b) { string flag;//和的字符串保存在flag里面 int lena=...
2020-04-06 00:09:16 223
原创 lg1328 生活大爆炸版石头剪刀布(模拟、打表)
题目 代码:(方法打表) #include<stdio.h> #include<stdlib.h> int main() { int n,na,nb,i,j; int a[203]={0},b[203]={0}; int flag1[203]={0},flag2[203]={0}; int counta=0,countb=0,sum=0...
2020-04-05 02:05:32 238
原创 2670扫雷游戏(模拟、字符串、二维数组)
题目 代码1: #include <iostream> #include<stdio.h> #include<stdlib.h> using namespace std; int main() { int d[102][102]={0};//用来存放整型的输出结果 int i,j,n,m;//n行m列,n行,每行m个字符 char a...
2020-04-04 18:50:22 238
原创 洛谷1478津津摘苹果(升级版)(排序、结构体、条件语句、贪心)
题目 第一次提交的代码:60分(2个测试点错误) #include <iostream> #include<stdio.h> #include<stdlib.h> #include<algorithm> using namespace std; struct apple { int high,p;//high是苹果的高度,p是摘该苹果需要...
2020-04-04 06:57:12 251
原创 lg1094纪念品分组(贪心)
1094纪念品分组(贪心) 代码链接 #include <iostream> #include<stdio.h> #include<stdlib.h> #include<algorithm> using namespace std; int main() { int w,n,i,j,k=0,count=0;//w为为每组纪念品价格之和的...
2020-04-03 00:48:59 215
原创 洛谷1208[USACO1.3]混合牛奶 Mixing Milk
https://www.luogu.com.cn/problem/P1208 代码: #include <iostream> #include<stdio.h> #include<stdlib.h> #include<algorithm> using namespace std; struct milk { int p,a;//p为单价,a...
2020-04-02 16:44:13 297
原创 洛谷1803凌乱的yyy / 线段覆盖(贪心+排序)
题目: #include <iostream> #include<stdio.h> #include<stdlib.h> #include<algorithm> using namespace std; struct match//定义一个结构体 { int start;//开始时间 int end;//结束时间 }a[100000...
2020-04-01 17:12:02 292
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人