#### AC Code:
```cpp
#include <cstdio>
#include <cstring>
#define int long long
int f[25][25][25];
int w(int a,int b,int c){
if(a<=0||b<=0||c<=0)
return 1;
if(a>20||b>20||c>20)
return w(20,20,20);
if (f[a][b][c] != -1) {
return f[a][b][c];
}
return f[a][b][c] = w(a-1,b,c)+w(a-1,b-1,c)+w(a-1,b,c-1)-w(a-1,b-1,c-1);
}
signed main(){
memset(f, -1, sizeof(f));
int i,a=0,b=0,c=0;
scanf("%lld%lld%lld",&a,&b,&c);
for(i=0;a!=-1||b!=-1||c!=-1;i++){
printf("w(%lld, %lld, %lld) = %lld\n",a,b,c,w(a,b,c));
scanf("%lld%lld%lld",&a,&b,&c);
}
return 0;
}
```
by Gcc_Gdb_7_8_1 @ 2024-08-07 17:09:51
求帖终~~QAQ~~
by Gcc_Gdb_7_8_1 @ 2024-08-07 20:39:43
_~~同时求互关~~_
by Gcc_Gdb_7_8_1 @ 2024-08-07 21:42:42
@[IaLWH](/user/486727) 已关
by Gcc_Gdb_7_8_1 @ 2024-08-08 13:02:16