递推与递归 \ DFS深度优先搜索 2025-2-27 11:30 | 1,157 | 0 | 术理共探 900 字 | 36 分钟 原题单链接:https://www.luogu.com/paste/vjf2z3hi || https://rentry.org/5yhk52ow 例题 跳台阶 #include <bits/stdc++.h> using namespace std; const int N=1e5; int a[N]; int f(int n) { … C/C++DFS算法递归递推
进制转换 2025-2-18 11:11 | 994 | 0 | 术理共探 69 字 | 3 分钟 十进制转其他进制 #include <bits/stdc++.h> using namespace std; string s="0123456789ABCDEF"; void solve(int x,int m) { // 递归 if(x/m) solve(x/m,m); cout<<s[x%m]; /… 算法进制递归