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. (转)减少oracle sql回表次数 提高SQL查询性能

    要写出高效的SQL,那么必须必须得清楚SQL执行路径,介绍如何提高SQL性能的文章很多,这里不再赘述,本人来谈谈如何从 减少SQL回表次数 来提高查询性能,因为回表将导致扫描更多的数据块. 我们大家都 ...

  2. hbase问题总结

    一.客户端访问hbase时出现no further information 使用java api访问hbase时,一直连不上,查看日志发现以下错误: java.net.ConnectException ...

  3. MySQL主从复制(Master-Slave)

    MySQL数据库自身提供的主从复制功能可以方便的实现数据的多处自动备份,实现数据库的拓展.多个数据备份不仅可以加强数据的安全性,通过实现读写分离还能进一步提升数据库的负载性能. 下图就描述了一个多个数 ...

  4. JAVA-基础(三)

    Character 类型字符(Character)是围绕字符型(char)的一个简单的包装器.字符(Character)的构造函数如下:Character(char ch)这里ch指定了被创建的字符( ...

  5. monkey测试工具与常用的linux命令

    Monkey测试工具 说明:monkey是一个安卓自带的命令行工具,可以模拟用户向应用发起一定的伪随机事件.主要用于对app进行稳定性测试与压力测试. 实现:首先需要安装一个ADB工具,安装完之后,需 ...

  6. python - 文件处理/open

    # -*- coding:utf-8 -*- '''@project: jiaxy@author: Jimmy@file: study_文件处理.py@ide: PyCharm Community E ...

  7. bat 文件读取乱码问题

    使用 for 循环 type file1.txt > file2.txt 文件读取后可能会出现乱码,需要在 bat 文件中设置 chcp 表示将批处理设置为 utf-8 编码,这样在生成文件和读 ...

  8. 聊聊、Nginx 安装启动

    首先说下安装 Nginx 的步骤: (1)window 下安装 进入 http://nginx.org/en/download.html 下载版本 Mainline version 或者 Stable ...

  9. [python工具][2]sublime的快捷键

    十.Sublime Text 快捷键列表 快捷键按类型分列如下: 1.通用  ↑↓← →    上下左右移动光标 Alt    调出菜单 Ctrl + Shift + P    调出命令板(Comma ...

  10. 九度oj 题目1184:二叉树遍历

    题目描述: 编一个程序,读入用户输入的一串先序遍历字符串,根据此字符串建立一个二叉树(以指针方式存储). 例如如下的先序遍历字符串:ABC##DE#G##F###其中“#”表示的是空格,空格字符代表空 ...