Problem description

There is a game called "I Wanna Be the Guy", consisting of n levels. Little X and his friend Little Y are addicted to the game. Each of them wants to pass the whole game.

Little X can pass only p levels of the game. And Little Y can pass only q levels of the game. You are given the indices of levels Little X can pass and the indices of levels Little Y can pass. Will Little X and Little Y pass the whole game, if they cooperate each other?

Input

The first line contains a single integer n (1 ≤  n ≤ 100).

The next line contains an integer p (0 ≤ p ≤ n) at first, then follows p distinct integers a1, a2, ..., ap (1 ≤ ai ≤ n). These integers denote the indices of levels Little X can pass. The next line contains the levels Little Y can pass in the same format. It's assumed that levels are numbered from 1 to n.

Output

If they can pass all the levels, print "I become the guy.". If it's impossible, print "Oh, my keyboard!" (without the quotes).

Examples

Input

4
3 1 2 3
2 2 4

Output

I become the guy.

Input

4
3 1 2 3
2 2 3

Output

Oh, my keyboard!

Note

In the first sample, Little X can pass levels [1 2 3], and Little Y can pass level [2 4], so they can pass all the levels both.

In the second sample, no one can pass level 4.

解题思路:标记一下1~n出现的数字,如果都出现了,则输出"I become the guy.",否则输出"Oh, my keyboard!",水过!

AC代码:

 #include<bits/stdc++.h>
using namespace std;
int main(){
int n,p,q,x;bool flag=false,used[];
memset(used,false,sizeof(used));
cin>>n>>p;
for(int i=;i<=p;++i){cin>>x;used[x]=true;}
cin>>q;
for(int i=;i<=q;++i){cin>>x;used[x]=true;}
for(int i=;i<=n;++i)
if(!used[i]){flag=true;break;}
if(flag)cout<<"Oh, my keyboard!"<<endl;
else cout<<"I become the guy."<<endl;
return ;
}

A - I Wanna Be the Guy的更多相关文章

  1. 题目1162:I Wanna Go Home(最短路径问题进阶dijkstra算法))

    题目链接:http://ac.jobdu.com/problem.php?pid=1162 详解链接:https://github.com/zpfbuaa/JobduInCPlusPlus 参考代码: ...

  2. BNUOJ 52308 We don't wanna work! set模拟

    题目链接: https://acm.bnu.edu.cn/v3/problem_show.php?pid=52308 We don't wanna work! Time Limit: 60000msM ...

  3. HDU 5308 I Wanna Become A 24-Point Master(2015多校第二场)

    I Wanna Become A 24-Point Master Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/65536 ...

  4. 2015多校联合训练赛 hdu 5308 I Wanna Become A 24-Point Master 2015 Multi-University Training Contest 2 构造题

    I Wanna Become A 24-Point Master Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/65536 ...

  5. HDU 5308 I Wanna Become A 24-Point Master

    题目链接: http://acm.hdu.edu.cn/showproblem.php?pid=5308 题面: I Wanna Become A 24-Point Master Time Limit ...

  6. 2015 Multi-University Training Contest 2 hdu 5308 I Wanna Become A 24-Point Master

    I Wanna Become A 24-Point Master Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/65536 ...

  7. When you want to succeed as bad as you wanna breathe, then you’ll be successful.

    上周末登了次山,回来就各种矫情犯懒.今天周四一周又要完蛋,我发现自己真的是对时间流逝无可奈何.然后中午看了把小码哥网站还有MJ博客什么的,各种首期班大爆照,心中羞愧无比.年纪大也不能放弃自己啊,要不人 ...

  8. We don't wanna work!

    We don't wanna work! [JAG Asia 2016] 两个set,一个代表工作的,一个代表不工作的 其实是一个很简单的模拟,但是我竟然排序之前标号.... 检查代码的时候要从头开始 ...

  9. 2016弱校联盟十一专场10.3---We don't wanna work!(STL--set的使用)

    题目链接 https://acm.bnu.edu.cn/v3/contest_show.php?cid=8504#problem/C 代码如下: #include <iostream> # ...

随机推荐

  1. JAVA软件工程师应该具备哪些基本素质?

    必知:软件企业要求基础软件工程师具备六大基本素质,即良好的编码能力.自觉的规范意识和团队精神.认识和运用数据库的能力.较强的英语阅读和写作能力.具有软件工程的概念和求知欲和进取心. 1.良好的编码能力 ...

  2. 学习廖雪峰的Python教程之数据类型

    数据类型 计算机顾名思义就是可以做数学计算的机器,因此,计算机程序理所当然地可以处理各种数值.但是,计算机能处理的远不止数值,还可以处理文本.图形.音频.视频.网页等各种各样的数据,不同的数据,需要定 ...

  3. Scala类型系统——高级类类型(higher-kinded types)

    高级类类型就是使用其他类型构造成为一个新的类型,因此也称为 类型构造器(type constructors).它的语法和高阶函数(higher-order functions)相似,高阶函数就是将其它 ...

  4. Docker系列之入门

    Docker基本介绍 一.什么是Docker 在docker的官方之什么是docker中提到了一句话:“当今各大组织或者团体的创新都源于软件(例如OA.ERP等),其实很多公司都是软件公司" ...

  5. JAVA 生成扫描条形码

    声明:转载为个人学习收藏,如有侵权,请及时联系本人删除,转载地址:https://www.cnblogs.com/MariaWang/p/10837641.html 条形码是一种可视化.机器可读的数据 ...

  6. luoguP4719 【模板】动态 DP 线段树+树链剖分+矩阵乘法+动态DP

    题目描述 给定一棵n个点的树,点带点权. 有m次操作,每次操作给定x,y,表示修改点x的权值为y. 你需要在每次操作之后求出这棵树的最大权独立集的权值大小. 输入输出格式 输入格式: 第一行,n,m分 ...

  7. 【转载】Java IO基础总结

    Java中使用IO(输入输出)来读取和写入,读写设备上的数据.硬盘文件.内存.键盘......,根据数据的走向可分为输入流和输出流,这个走向是以内存为基准的,即往内存中读数据是输入流,从内存中往外写是 ...

  8. Restrictions.like("字段field","%表达式exp%");

    Restrictions.like("字段field","%表达式exp%");用hql语句就是 from table where field like '%e ...

  9. appium分层自动化的封装

    1.创建一个case包,start_app的python文件 #coding=utf-8from appium import webdriverfrom util.read_init import R ...

  10. 洛谷 P1595 信封问题

    题目描述 某人写了n封信和n个信封,如果所有的信都装错了信封.求所有信都装错信封共有多少种不同情况. 输入输出格式 输入格式: 一个信封数n 输出格式: 一个整数,代表有多少种情况. 输入输出样例 输 ...