【水题】 Codeforces Round #289 509A Maximum in Table
来源:互联网 发布:东南大学网络 编辑:程序博客网 时间:2024/06/07 05:39
题意:
a[i][j]=a[i-1][j]+a[i][j-1];
#include <cstdio>#include <cstring>#include <cstdlib>#include <string>#include <iostream>#include <algorithm>#include <sstream>#include <cmath>using namespace std;#include <queue>#include <stack>#include <set>#include <vector>#include <deque>#include <map>#define cler(arr, val) memset(arr, val, sizeof(arr))typedef long long LL;const int MAXN = 120000;const int MAXM = 140000;const int INF = 0x3f3f3f3f;const int mod = 1000000007;#define lson l,m,rt<<1#define rson m+1,r,rt<<1|1int main(){ int n,a[22][22]; cin>>n; for(int i=1;i<=n;i++) a[1][i]=a[i][1]=1; for(int i=2;i<=n;i++) for(int j=2;j<=n;j++) a[i][j]=a[i-1][j]+a[i][j-1]; cout<<a[n][n]<<endl;}
0 0
- 【水题】 Codeforces Round #289 509A Maximum in Table
- A. Maximum in Table( Codeforces Round #289)
- CodeForces 509A Maximum in Table
- Codeforces Round #289 (Div. 2, ACM ICPC Rules) -- A. Maximum in Table
- codeforces——509A—— Maximum in Table
- Codeforces Maximum in Table
- A. Maximum in Table
- A. Maximum in Table
- A - Maximum in Table
- CF 509A(Maximum in Table-暴力)
- Codefroces 289 div2 A.Maximum in Table (打表)
- Codeforces Round #209 (Div. 2) A. Table
- Codeforces Round #209 (Div. 2) A.Table
- Codeforces Round #440 (Div. 1) A. Maximum splitting
- Codeforces Round #389 (Div. 2)A. Santa Claus and a Place in a Class(水题)
- Codeforces Round #100 (Div. 2) A - New Year Table
- A. Vanya and Table(Codeforces Round #308 (Div. 2))
- Codeforces Round #308 (Div. 2) A. Vanya and Table
- 【Android应用开发】Intent和PendingIntent的区别
- RadioStream应用源码完整版(iphone版和ipad版)
- 使用ajaxFileUpload实现文件异步上传
- jsp页面引入的标签库
- 【已解决】【奇葩5】iOS 定位到香港
- 【水题】 Codeforces Round #289 509A Maximum in Table
- MVC之-- ViewData vs ViewBag vs TempData vs Session
- live555源代码分析与代码下载链接
- 最快最简单的排序——桶排序
- 更简约的用户账号设计:只需要本人实际姓名、E-mail和手机号码任选其一,无需密码
- 前一段时间没事用c#写了一个串口程序,这里总结一下自己的经验
- 使用 DrMemory 发现内存编程错误
- mysql安装
- MAP文件和调试(VC)(从崩溃地址找出错源码位置)