solution-code2593
每种水的生成函数
第 1 种:
第 2 种:
第 3 种:
第 4 种:
第 5 种:
乘在一起得到:
带入广义二项式定理得:
当
所以答案就为
#include <iostream>#include <cstdio>#include <cstring>#include <algorithm>using namespace std;int main(void){ int n; scanf("%d",&n); printf("%lld\n",1LL*(n+1)*(n+2)/2); return 0;}