A. In Search of an Easy Problem
time limit per test

1 second

memory limit per test

256 megabytes

input

standard input

output

standard output

When preparing a tournament, Codeforces coordinators try treir best to make the first problem as easy as possible. This time the coordinator had chosen some problem and asked nn people about their opinions. Each person answered whether this problem is easy or hard.

If at least one of these nn people has answered that the problem is hard, the coordinator decides to change the problem. For the given responses, check if the problem is easy enough.

Input

The first line contains a single integer nn (1≤n≤1001≤n≤100) — the number of people who were asked to give their opinions.

The second line contains nn integers, each integer is either 00 or 11. If ii-th integer is 00, then ii-th person thinks that the problem is easy; if it is 11, then ii-th person thinks that the problem is hard.

Output

Print one word: "EASY" if the problem is easy according to all responses, or "HARD" if there is at least one person who thinks the problem is hard.

You may print every letter in any register: "EASY", "easy", "EaSY" and "eAsY" all will be processed correctly.

Examples
input

Copy
3
0 0 1
output

Copy
HARD
input

Copy
1
0
output

Copy
EASY

为了熟悉CF。忍了。。
#include<iostream>
#include<cstdlib>
using namespace std; int main(){
int n;
char* hard= "HARD";
char* easy= "EASY";
cin>>n;
for(int i=;i<n;i++){
int c;
cin>>c;
if(c==){
cout<<hard;
exit();
}
}
cout<<easy;
return ;
}

codeforces A. In Search of an Easy Problem的更多相关文章

  1. CodeForces - 1058A. In Search of an Easy Problem

    这题,全零是esay有1是hard,真难呀. #include<bits/stdc++.h> using namespace std; int main(){ int n,i,x,flag ...

  2. 2018.09.23 codeforces 1053A. In Search of an Easy Problem(gcd)

    传送门 今天的签到题. 有一个很显然的结论,gcd(n∗m,k)≤2gcd(n*m,k)\le 2gcd(n∗m,k)≤2. 本蒟蒻是用的行列式求三角形面积证明的. 如果满足这个条件,就可以直接构造出 ...

  3. CF1030A 【In Search of an Easy Problem】

    题目巨简单,主要是给大家翻译一下 给n个数,其中存在1就输出HARD,否则输出EASY,不区分大小写 #include<iostream> #include<cstdio> u ...

  4. buaa 1033 Easy Problem(三分)(简单)

    Easy Problem 时间限制:1000 ms  |  内存限制:65536 KB 描写叙述 In this problem, you're to calculate the distance b ...

  5. CF 1096D Easy Problem [动态规划]

    题目链接:http://codeforces.com/problemset/problem/1096/D 题意: 有一长度为n的字符串,每一字符都有一个权值,要求现在从中取出若干个字符,使得字符串中没 ...

  6. UVA-11991 Easy Problem from Rujia Liu?

    Problem E Easy Problem from Rujia Liu? Though Rujia Liu usually sets hard problems for contests (for ...

  7. An easy problem

    An easy problem Time Limit:3000MS     Memory Limit:32768KB     64bit IO Format:%I64d & %I64u Sub ...

  8. UVa 11991:Easy Problem from Rujia Liu?(STL练习,map+vector)

    Easy Problem from Rujia Liu? Though Rujia Liu usually sets hard problems for contests (for example, ...

  9. POJ 2826 An Easy Problem?!

    An Easy Problem?! Time Limit: 1000MS   Memory Limit: 65536K Total Submissions: 7837   Accepted: 1145 ...

随机推荐

  1. Python学习笔记(一):基础知识

    一.什么是python? python是一种面向对象.解释型的计算机语言,它的特点是语法简洁.优雅.简单易学 二.编译型语言和解释型语言 编译型语言就是把程序编译成计算机语言然后执行,(一次编译到处运 ...

  2. CSS 预处理器框架

    CSS 预处理器框架 可以按照需求来使用别人的代码 1.sass (compass) 2.less (lesshat/EST) 3.提供现成的 mixin 4.类似 JS 类库 ,封装常用功能 css ...

  3. BZOJ 4896: [Thu Summer Camp2016]补退选

    trie树+vector+二分 别忘了abs(ans) #include<cstdio> #include<algorithm> #include<vector> ...

  4. python基础学习笔记—— 多继承

    本节主要内容: 1.python多继承 2.python经典类的MRO 3.python新式类的MRO.C3算法 4.super是什么鬼? 一.python多继承 在前⾯的学习过程中. 我们已经知道了 ...

  5. Python学习-day5 常用模块

    day5主要是各种常用模块的学习 time &datetime模块 random os sys shutil json & picle shelve xml处理 yaml处理 conf ...

  6. match_parent, wrap_content, 和 fill_parent 区别联系

    fill_parent   -1  The view should be as big as its parent (minus padding). This constant is deprecat ...

  7. TOJ1840: Jack Straws 判断两线段相交+并查集

    1840: Jack Straws  Time Limit(Common/Java):1000MS/10000MS     Memory Limit:65536KByteTotal Submit: 1 ...

  8. Android监听键盘右下角确定键

    代码改变世界 Android监听键盘右下角确定键 kotlin写法 <EditText android:id="@+id/seachFriend" android:layou ...

  9. iOS学习笔记39-ReactiveCocoa入门

    FRP,全称为Functional Reactive Programming,是一种响应变化的编程范式,最近几年比较火,大概的理解就像这样: 当a的值或者b的值发生变化时,c的值会自动响应a的值或b的 ...

  10. iOS学习笔记01-APP相关

    AppDelegate对象方法 # 程序第一次启动后才会执行 - (BOOL)application:(UIApplication *)application didFinishLaunchingWi ...