hdoj 2052 picture
来源:互联网 发布:mac系统序列号查询 编辑:程序博客网 时间:2024/06/06 23:14
Picture
Time Limit: 1000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 23172 Accepted Submission(s): 11813
Problem Description
Give you the width and height of the rectangle,darw it.
Input
Input contains a number of test cases.For each case ,there are two numbers n and m (0 < n,m < 75)indicate the width and height of the rectangle.Iuput ends of EOF.
Output
For each case,you should draw a rectangle with the width and height giving in the input.
after each case, you should a blank line.
after each case, you should a blank line.
Sample Input
3 2
Sample Output
+---+| || |+---+
Author
xhd
Source
校庆杯Warm Up
Recommend
linle | We have carefully selected several similar problems for you: 2054 2072 2053 2055 2056
注意输出空格
#include<stdio.h>#include<string.h>#include<algorithm>using namespace std;int main(){int i,j,k,m,n;char a[110],b[110];while(scanf("%d%d",&m,&n)!=EOF){for(i=1;i<=n+2;i++){if(i==1||i==n+2){printf("+");for(j=2;j<m+2;j++)printf("-");printf("+\n"); }else{printf("|");for(j=2;j<m+2;j++)printf(" ");printf("|\n");}}printf("\n");}return 0;}
0 0
- HDOJ 2052 Picture
- Picture hdoj 2052
- hdoj.2052 Picture 20140804
- Picture(HDOJ-2052)
- HDOJ 2052 Picture
- hdoj 2052 picture
- HDOJ-2052(Picture)
- HDOJ 2052 Picture
- hdoj 2052 Picture
- HDOJ 2052 Picture
- HDOJ 2052 Picture(暑期练习)
- HDOJ Eddy's picture
- HDOJ 1162 Eddy's picture
- HDOJ Eddy's picture 1162
- hdoj-1162-Eddy's picture
- hdoj 1162 Eddy's picture
- 【hdoj 1162】Eddy's picture
- HDOJ 1162 Eddy's picture
- UVa 213 Message Decoding
- Unity 摄像机
- Educational Codeforces Round 7
- 87
- nginx高级配置
- hdoj 2052 picture
- 110. Balanced Binary Tree LeetCode
- HDU3488 Cyclic Tour(有向环最小覆盖)
- hdu2457 DNA repair(AC自动机+dp)
- linux 安装 percona-toolkit
- neuq oj 1017平面切割(特别版)C++
- firewalld自定义服务名及端口
- 101. Symmetric Tree LeetCode
- webroot和web-inf的区别