bzoj1600
来源:互联网 发布:合肥兆度网络骗 编辑:程序博客网 时间:2024/05/17 23:18
n 条边围成 n 边形的条件。。。。
#include<bits/stdc++.h>using namespace std;#define FOR(i,s,t) for(int i=(s);i<=(t);i++)inline int read(void){ int x = 0, c, f = 1; do{c=getchar();if(c=='-')f=-1;}while(c<'0'||c>'9'); do{x=x*10+c-'0';c=getchar();}while(c>='0'&&c<='9'); return x * f;}typedef long long LL;LL f[2555][5];int main(){ f[0][0] = 1; int n = read(), mx = (n + 1) / 2 - 1; for (int i = 1; i <= 4; i++) for (int j = 1; j <= n; j++) for (int k = 1; k <= min(j,mx); k++) f[j][i] += f[j - k][i - 1]; cout << f[n][4] << endl;}
阅读全文
0 0
- bzoj1600
- bzoj1600
- bzoj1600(排列组合)
- bzoj1600 [Usaco2008 Oct]建造栅栏
- [BZOJ1600][Usaco2008 Oct]建造栅栏
- bzoj1600 [Usaco2008 Oct]建造栅栏
- 【bzoj1600】【USACO2008 Oct】Building A Fence 建造栅栏
- Android 从输入设备获取消息
- Schema和DTD的区别
- jquery获取tr本行id属性
- Spring全家桶(四)Bean的生命周期
- 【opencv】openCV生成标定相机用的黑白棋盘
- bzoj1600
- Android 中的消息机制
- Sublime Text 3 LESS、SASS、SCSS高亮插件、提示插件
- AFL(American Fuzzy Lop)使用(二)
- Ambari 架构(译文)
- Java 8 实战学习——行为参数化
- Hrbust 1788 Chocolate【Dp】
- Tensorflow lesson 6---层 layer
- not all arguments converted during string formatting