Sloution
没啥好说的,两个01背包维度
const int N = 210;
int n, M,T;
int a[N], b[N];
int f[N][N];
int main(){
//freopen("in.txt", "r", stdin);
cin >> n >> M>>T;
_for(i,0,n){
cin >> a[i] >> b[i];
}
_for(i,0,n){
for (int j = M; j >= a[i];j--){
for (int k = T; k >= b[i];k--)
f[j][k] = max(f[j][k], f[j - a[i]][k - b[i]] + 1);
}
}
cout << f[M][T];
}