码迷,mamicode.com
首页 > 其他好文 > 详细

【入门OJ】1064:斜角Ⅰ

时间:2017-09-15 22:37:17      阅读:230      评论:0      收藏:0      [点我收藏+]

标签:ret   mil   str   algo   div   sed   none   bsp   stream   

技术分享

只要不斜着斜着看,横着看很美好的!亲爱的对角线也没有了QAQ

技术分享
#include<iostream>
#include<cstring>
#include<cstdio>
#include<algorithm>
#define MAXN
using namespace std;
int n;

int main(){
    scanf("%d",&n);
    for(int i=1;i<=n;i++){
        for(int j=i;j<=i+n-1;j++){
            printf("%3d",j);
        }
        printf("\n");
    }
    return 0;
}
斜角I

 

【入门OJ】1064:斜角Ⅰ

标签:ret   mil   str   algo   div   sed   none   bsp   stream   

原文地址:http://www.cnblogs.com/Parry-PY/p/7528681.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!