ZyWoOoO
ZyWoOoO
全部文章
分类
归档
标签
去牛客网
登录
/
注册
ZyWoOoO的博客
全部文章
(共21篇)
题解 | 最长回文子序列
#include <bits/stdc++.h> using namespace std; const int MAXN = 1000 + 10; int dp[MAXN][MAXN]; string str; int n; int main() { cin >> s...
2025-05-14
0
27
题解 | 滑雪
#include <bits/stdc++.h> using namespace std; const int MAXN = 1001; int f[MAXN][MAXN]; int dir[4][2] = {{0,1},{1,0},{0,-1},{-1,0}}; int dp[MAXN...
2025-05-14
0
34
题解 | 游游的数值距离
#include <bits/stdc++.h> using namespace std; #define int long long int f[] = {0, 1, 0, 6, 24, 120, 720, 5040, 40320, 362880, 3628800, 39916800...
2025-05-13
0
30
题解 | 最少的完全平方数
#include <bits/stdc++.h> using namespace std; #define int long long const int MAXN = 1e4 + 5; int dp[MAXN]; signed main() { int n;cin >&g...
2025-05-11
0
31
题解 | 串
#include <bits/stdc++.h> using namespace std; #define int long long const int MOD = 1e9 + 7; const int MAXN = 1e6 + 10; int f[MAXN] = {0,26}; s...
2025-05-11
0
33
题解 | 数位染色
#include <bits/stdc++.h> using namespace std; const int MAXN = 19; bool dp[MAXN][MAXN * 9 + 1];//根据题意开个18层,因为我下标从1开始就定19了,每位数都有9种可能 int main() ...
2025-05-05
0
31
题解 | 小红的排列构造
#include <bits/stdc++.h> using namespace std; #define int long long const int N = 1e5 + 10; signed main() { int n;cin >> n; //当n小于...
2025-05-05
0
32
题解 | 跳台阶
class Solution { public: /** * 代码中的类名、方法名、参数名已经指定,请勿修改,直接返回方法规定的值即可 * * * @param number int整型 ...
2025-04-24
0
35
题解 | 斐波那契数列
#include <bits/stdc++.h> using namespace std; const int N = 1e5 + 5; int f[N]; int main() { int n;cin >> n; f[1] = f[2] = 1;//根据斐波...
2025-04-24
0
22
题解 | 括号区间匹配
#include <bits/stdc++.h> using namespace std; const int MAXN = 110; int dp[MAXN][MAXN]; int main() { string s; cin >> s; int n = ...
2025-04-24
0
30
首页
上一页
1
2
3
下一页
末页