05 2022 档案

摘要:acwing 阅读全文
posted @ 2022-05-27 21:08 兮何其 阅读(9) 评论(0) 推荐(0) 编辑
摘要:##分支算法 ###题意描述: 在2k * 2k的正方形棋盘上有一个缺口,这里可以认为是已经被填充了,要求给出使用三角板去填满这个棋盘的方案 #include <iostream> using namespace std; int amount,Board[100][100]; void Cover 阅读全文
posted @ 2022-05-21 15:13 兮何其 阅读(63) 评论(0) 推荐(0) 编辑
摘要:#include <iostream> using namespace std; const int N = 100010, MOD = 1e9 + 7; int n1, n2, m; // n1种普通币,n2种纪念币,凑成面值m int f[N]; // 背包问题:完全背包(普通币) + 0/1背 阅读全文
posted @ 2022-05-17 21:34 兮何其 阅读(20) 评论(0) 推荐(0) 编辑
摘要:csdn 阅读全文
posted @ 2022-05-17 21:28 兮何其 阅读(7) 评论(0) 推荐(0) 编辑
摘要:#include <iostream> #include <algorithm> #include <cstring> using namespace std; const int N = 1010; int a[N], b[N]; int n; int main() { while(cin >> 阅读全文
posted @ 2022-05-17 20:42 兮何其 阅读(20) 评论(0) 推荐(0) 编辑
摘要:#include <cstdio> #include <cstring> #include <iostream> #include <algorithm> using namespace std; const int N = 100010; int n; int a[N], f[N], g[N]; 阅读全文
posted @ 2022-05-17 20:40 兮何其 阅读(54) 评论(0) 推荐(0) 编辑
摘要:#include <cstdio> #include <cstring> #include <iostream> #include <algorithm> using namespace std; const int N = 10010; int n; struct Segment { int x, 阅读全文
posted @ 2022-05-15 17:25 兮何其 阅读(26) 评论(0) 推荐(0) 编辑
摘要:####不修改val的值,只改变链表结构,时间复杂度O (nlgn), 额外空间O(lgn) class Solution { public: ListNode* getTail(ListNode *head){ while(head->next){ head = head->next; } ret 阅读全文
posted @ 2022-05-15 15:33 兮何其 阅读(48) 评论(0) 推荐(0) 编辑
摘要:ACwing class Solution { public: vector<int> getMinimumValue(int n) { const int INF = ~(1 << 31); //自然是有符号数的最大值 int l = 0, r = n - 1; //二分边界 while(l <= 阅读全文
posted @ 2022-05-15 15:23 兮何其 阅读(41) 评论(0) 推荐(0) 编辑
摘要:ACwing 阅读全文
posted @ 2022-05-15 15:05 兮何其 阅读(17) 评论(0) 推荐(0) 编辑
摘要:#include <bits/stdc++.h> using namespace std; const int N = 1010; int n,m; int cnt; int mp[N][N]; int ans[N*N]; //mp 该点所属连通块的标号, ans表示该连通块的大小 char g[N 阅读全文
posted @ 2022-05-14 20:35 兮何其 阅读(35) 评论(0) 推荐(0) 编辑
摘要:ACwing 空调 阅读全文
posted @ 2022-05-14 13:40 兮何其 阅读(18) 评论(0) 推荐(0) 编辑
摘要:csdn 能添加&符号的就是左值,否则就是右值,匿名变量一律都属于右值 阅读全文
posted @ 2022-05-04 17:42 兮何其 阅读(22) 评论(0) 推荐(0) 编辑
摘要:blog 阅读全文
posted @ 2022-05-04 17:23 兮何其 阅读(22) 评论(0) 推荐(0) 编辑
摘要:vector的find函数 int pos=s.find(' '); 返回vector中第一个' '的下标 阅读全文
posted @ 2022-05-03 10:30 兮何其 阅读(80) 评论(0) 推荐(0) 编辑
摘要:csdn bolg 阅读全文
posted @ 2022-05-02 14:58 兮何其 阅读(5) 评论(0) 推荐(0) 编辑
摘要:csdn 阅读全文
posted @ 2022-05-01 10:58 兮何其 阅读(20) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示