1663: 字符识别?
来源:互联网 发布:初学室内设计的软件 编辑:程序博客网 时间:2024/06/06 00:50
1663: 字符识别?
Time Limit: 1 Sec Memory Limit: 128 MBSubmit: 84 Solved: 52
[Submit][Status][Web Board]
Description
你的任务是写一个程序进行字符识别。别担心,你只需要识别1, 2, 3,如下:
.*. *** ***
.*. ..* ..*
.*. *** ***
.*. *.. ..*
.*. *** ***
Input
输入仅包含一组数据,由6行组成。第一行为字符的个数n(1<=n<=10)。以下5行每行包含4n个字符。每个字符恰好占5行3列,然后是一个空列(用"."填充)。
Output
输出应包含一行,即识别出的各个字符。
Sample Input
3
.*..***.***.
.*....*...*.
.*..***.***.
.*..*.....*.
.*..***.***.
Sample Output
123
HINT
Source
由于只有第四行互不相同,所以只要判断该行就行了#include<cstdio>int main(){ int n,i,j,k;char a[50],b[50]; while(~scanf("%d",&n)){ getchar(); for(i=0;i<5;i++){ if(i==3)scanf("%s",a); else scanf("%s",b); } for(j=0;j<n*4;j++){ if(a[j]=='*'){ if(j%4==1)printf("1"); else if(j%4==0)printf("2"); else if(j%4==2)printf("3"); } } printf("\n"); }}
阅读全文
0 0
- 1663: 字符识别?
- 1663: 字符识别?
- 字符识别
- 字符识别?
- 字符识别?
- 车牌识别 字符识别
- ocr 字符识别 项目
- tesseract-ocr识别字符
- 如何识别字符编码
- OCR字符识别
- .字符的匹配识别
- 光学字符识别 OCR
- shape context字符识别
- 光学字符识别 OCR
- mnist-字符识别
- 数码管字符识别
- C - 字符识别?
- 车牌识别-字符分割
- Box Relations(拓扑排序)
- 公钥证书编码解读
- 快学numpy02
- 笨方法学Python 习题 44: 继承(Inheritance) VS 合成(Composition)
- 小白笔记--------------------------leetcode 34. Search for a Range
- 1663: 字符识别?
- No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK
- 字符串操作总结
- Spring Boot学习第一季(DB交互)
- Servlet+JSP开发简单实例
- java.lang.ClassNotFoundException: org.apache.commons.io.output.DeferredFileOutputStr
- 远程连接MySQL出现host is not allowed to connect to this mysql server
- C#基础之匿名方法实例教程
- 云服务器 ECS弹性变配能力总览