Picture

Time Limit: 1000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)
Total Submission(s): 72 Accepted Submission(s): 59
 
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.
 
Sample Input
3 2
 
Sample Output
+---+
| |
| |
+---+
 
Author
xhd
 
Source
校庆杯Warm Up
 
Recommend
linle

/*
题意:画一个n*m的小盒子 初步思路:略
*/
#include<bits/stdc++.h>
using namespace std;
int n,m;
int main(){
// freopen("in.txt","r",stdin);
while(scanf("%d%d",&n,&m)!=EOF){
printf("+");
for(int i=;i<n;i++) printf("-");
printf("+\n");
for(int i=;i<m;i++){
printf("|");
for(int j=;j<n;j++){
printf(" ");
}
printf("|\n");
}
printf("+");
for(int i=;i<n;i++) printf("-");
printf("+\n\n");
}
return ;
}

Picture的更多相关文章

  1. 基于Picture Library创建的图片文档库中的上传多个文件功能(upload multiple files)报错怎么解决?

    复现过程 首先,我创建了一个基于Picture Library的图片文档库,名字是 Pic Lib 创建完毕后,我点击它的Upload 下拉菜单,点击Upload Picture按钮 在弹出的对话框中 ...

  2. MFC Picture控件加载图片

    CStatic *pPic = (CStatic*)GetDlgItem(IDC_PICTURE); CBitmap bitmap; bitmap.LoadBitmapW(IDB_BITMAP2); ...

  3. [POJ1177]Picture

    [POJ1177]Picture 试题描述 A number of rectangular posters, photographs and other pictures of the same sh ...

  4. USACO 5.5 Picture(周长并)

    POJ最近做过的原题. /* ID: cuizhe LANG: C++ TASK: picture */ #include <cstdio> #include <cstring> ...

  5. 彩色照片转换为黑白照片(Color image converted to black and white picture)

    This blog will be talking about the color image converted to black and white picture. The project st ...

  6. HDU 1828 Picture(线段树扫描线求周长)

    Picture Time Limit: 6000/2000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Others) Total Su ...

  7. don't forget the bigger picture

    Imagine a circle that contains all of human knowledge: By the time you finish elementary school, you ...

  8. A Complete Guide to the <Picture> Element

    If you’ve ever struggled building responsive websites, this post is for you. It’s part of a series o ...

  9. HDUOJ-----(1162)Eddy's picture(最小生成树)

    Eddy's picture Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others)To ...

  10. IO流--复制picture ,mp3

    import java.io.BufferedReader; import java.io.BufferedWriter; import java.io.FileInputStream; import ...

随机推荐

  1. centOS7服务管理与启动流程

    centOS7服务管理与启动流程 centOS7启动流程 systemd简介 unit对象 unit类型 特性 service unit文件格式 service unit file文件通常由三部分组成 ...

  2. javascript DOM事件总结

    1 <html> 2 <title>事件</title> 3 <meta charset="utf-8"/> 4 <body& ...

  3. PHP获取文件的绝对路径

    1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 ===========PH ...

  4. Python之面向对象与类

    本节内容 面向对象的概念 类的封装 类的继承 类的多态 静态方法.类方法 和 属性方法 类的特殊成员方法 子类属性查找顺序 一.面向对象的概念 1. "面向对象(OOP)"是什么? ...

  5. Power Sum 竟然用原根来求

    Power Sum Time Limit: 20000/10000MS (Java/Others) Memory Limit: 128000/64000KB (Java/Others) SubmitS ...

  6. Perfect Pth Powers poj1730

    Perfect Pth Powers Time Limit: 1000MS   Memory Limit: 10000K Total Submissions: 16383   Accepted: 37 ...

  7. MySQL之增删改查

    前言:以下是MySQL最基本的增删改查语句,很多IT工作者都必须要会的命令,也是IT行业面试最常考的知识点,由于是入门级基础命令,所有所有操作都建立在单表上,未涉及多表操作. 前提:在进行" ...

  8. 冒泡排序(Bubble Sort)

    冒泡排序的基本思路 冒泡排序是一种效率极低的排序,首先它需要知道数组的有效数据长度,再对数据第一个和第二个两两比较,按照比较规则进行交换,然后第二个数据和第三个数据进行比较,按照比较规则进行交换:第一 ...

  9. 【DP】捡苹果

    #include<stdio.h> int max(int a,int b) { int c; if(a>b) c=a; else c=b; return c; } int main ...

  10. 【框架学习与探究之消息队列--EasyNetQ(1)】

    前言 本文欢迎转载,实属原创,本文原始链接地址:http://www.cnblogs.com/DjlNet/p/7603554.html 废话 既然都是废话了,所以大家就可以跳过了,这里是博主有事没事 ...