Gym 100112AAaah!
来源:互联网 发布:雨露计划app软件 编辑:程序博客网 时间:2024/06/06 11:44
Jon Marius shouted too much at the recent Justin Bieber concert, and now
needs to go to the doctor because of his sore throat. The doctor’s instructions
are to say “aaah”. Unfortunately, the doctors sometimes need Jon Marius to say
“aaah” for a while, which Jon Marius has never been good at. Each doctor requires
a certain level of “aah” – some require “aaaaaah”, while others can actually
diagnose his throat with just a “h”. (They often diagnose wrongly, but that is beyond
the scope of this problem.) Since Jon Marius does not want to go to a doctor
and have his time wasted, he wants to compare how long he manages to hold the
“aaah” with the doctor’s requirements. (After all, who wants to be all like “aaah”
when the doctor wants you to go “aaaaaah”?)
Each day Jon Marius calls up a different doctor and asks them how long his
“aaah” has to be. Find out if Jon Marius would waste his time going to the given
doctor.
Input
The input consists of two lines. The first line is the “aaah” Jon Marius is able
to say that day. The second line is the “aah” the doctor wants to hear. Only
lowercase ’a’ and ’h’ will be used in the input, and each line will contain between
0 and 999 ’a’s, inclusive, followed by a single ’h’.
Output
Output “go” if Jon Marius can go to that doctor, and output “no” otherwise.
Sample Input 1 Sample Output 1
aaah
aaaaah
no
Sample Input 2 Sample Output 2
aaah
ah
go
打的是代码,实则在学习英文,再来ccpc,icpc 比赛,英语6级指日可待
看代码 太水
#include<bits/stdc++.h>using namespace std;int main(){ string s2,s1; while(cin>>s1>>s2) { if(s1.length()>=s2.length()) puts("go"); else puts("no"); } return 0;}
- Gym 100112AAaah!
- Gym
- Gym
- Gym
- Gym
- Gym
- Gym
- Gym
- Gym
- Gym
- Gym
- Gym
- Gym
- Gym
- Gym
- Gym
- Gym
- Gym
- 10/21/22作业
- HAOI 2010 软件安装(Tarjan+树形dp)
- Web Service (014---webservice使用Jquery、Ajax请求WebService所遇到的跨域问题)
- java CommomUtils工具类
- my stl study-road<template.1>
- Gym 100112AAaah!
- 当装了多个tomcat后,如何修改tomcat端口
- python3 类对象的定义、方法
- JQGrid 动态添加 Select
- 直方图均衡原理及Matlab实现
- 天池历届大赛答辩PPT及视频
- Struts2:二
- Ubuntu上通过源码安装QEMU
- 三子棋