2013年6月18日

poj 1163 The Triangle

摘要: 题目链接:http://poj.org/problem?id=1163解题思路:核心为 a[i-1][j]=a[i-1][j]+max(a[i][j],a[i][j+1]), 其中 1 2 using namespace std; 3 4 int main(){ 5 int n,i,j,a[101][101]; 6 cin>>n; 7 for(i=1;i>a[i][j]; 9 }10 for(i=n;i>1;i--){11 for(j=1;ja[i][j+1]? a[i][j]:a[i][j+1]);13 }14 ... 阅读全文

posted @ 2013-06-18 23:27 SCNU20102200088 阅读(219) 评论(0) 推荐(0) 编辑

导航