12289 - One-Two-Three
来源:互联网 发布:怎么修改网络游戏数据 编辑:程序博客网 时间:2024/06/09 18:50
One-Two-Three
Your little brother has just learnt to write one, two and three, in English. He has written a lot of thosewords in a paper, your task is to recognize them. Note that your little brother is only a child, so he maymake small mistakes: for each word, there might be at most one wrong letter. The word length isalways correct. It is guaranteed that each letter he wrote is in lower-case, and each word he wrote has aunique interpretation.
Input
The first line contains the number of words that your little brother has written. Each of the followinglines contains a single word with all letters in lower-case. The words satisfy the constraints above: atmost one letter might be wrong, but the word length is always correct. There will be at most 10 wordsin the input.Output
For each test case, print the numerical value of the word.Sample Input
3owetootheee
Sample Output
123
#include<stdio.h>int main(){char s[6];int t,i;scanf("%d",&t);while(t--){scanf("%s",s);if(s[3]!='\0'){puts("3");continue;}if((s[0]=='o'&&s[1]=='n')||(s[0]=='o'&&s[2]=='e')||(s[2]=='e'&&s[1]=='n')) puts("1");else puts("2");}return 0;}
- 12289 - One-Two-Three
- UVa--12289 One-Two-Three
- UVa 12289 - One-Two-Three
- UVA 12289 One-Two-Three
- UVa 12289 One-Two-Three (water ver.)
- test one two three
- one,two,three
- ASP杂谈ONE、TWO、THREE
- ChargeSystem——One,Two,Three
- Experience Of Test One Two Three...
- crawler for one two three zero six
- uva 594 One Little, Two Little, Three Little Endians
- 如何实现将'one,two,three,four,five' 分别打印
- UVa 594 - One Little, Two Little, Three Little Endians
- queue by one stack、two stack and three stack
- 奥运英语[9]数字:1,2,3……10 Numbers: one, two, three...ten.
- I Count Two Three
- Timus 1495. One-two, One-two 2
- C语言经典例题100道 第8题
- linux 安装tree
- Csharp:Windowsform using CheckedListBox Datasource
- JCIFS NTLM HTTPAuthenticationJCIFS使用NTLMHTTP认证
- 一 数据库系统概述
- 12289 - One-Two-Three
- 2013/06/14面试
- jcifs包实现域认证的单点登录带来了个奇怪的问题
- linux下安装jdk1.6版本显示1.4,修改默认jdk版本
- Android学习笔记5:常用控件(1)
- Rescue the Rabbit HOJ4507
- ASP.NET 实现PDF文件下载
- 迅雷下载速度右边的分数代表的意思
- JCIFS