无限恒星
无限恒星
全部文章
分类
归档
标签
去牛客网
登录
/
注册
无限恒星的博客
全部文章
(共8篇)
题解 | #邮票#
/* 看了评论区,都不行,这才是动态规划解题 */ #include <iostream> #include <vector> using namespace std; int stamp[] = {8,8,8,8,8, 10,10,10,10, 18,18,18,18,1...
2024-06-13
0
201
题解 | #最小花费#
/* 这题,评论区的答案都没我写得好 */ #include <iostream> #include <vector> #include <climits> using namespace std; int L1, L2, L3, C1, C2, C3; int...
2024-05-13
0
191
题解 | #找x#
#include <iostream> #include <vector> #include <algorithm> using namespace std; int main() { int n; int target; vector&...
2024-05-11
0
176
题解 | #Fibonacci#
#include <iostream> using namespace std; //f1=1,f2=1,f3=2,f4=3 int main() { int n; while(cin >> n){ int a = 0, b = 1, c; ...
2024-05-07
0
162
题解 | #位操作练习#
//转化为匹配字符串 #include <iostream> #include <string> #include <algorithm> using namespace std; string intToString(int a); int main() {...
2024-04-30
0
205
题解 | #字符串内排序#
#include <iostream> #include <string> #include <algorithm> using namespace std; void swap(char &a, char &b){ char temp ...
2024-04-26
0
238
题解 | #后缀子串排序#
#include <iostream> #include <string> #include <vector> #include <algorithm> void print(std::vector<std::string> substr...
2024-04-25
0
198
题解 | #神奇的口袋#
#include <iostream> #include <vector> using namespace std; /** * 递归实现,空间开销大,时间开销大 * 二维数组实现(动态规划),空间开销大,时间快 * 一维数组实现(动态规划),空间和时间开销都很小 **/ ...
2024-04-24
0
194