本题递归求解 #include<iostream> #include<cstring> #include<cstdio> #include<cmath> using namespace std; int n,a,b,ans,v