Keep on Truckin'

Problem Description
Boudreaux and Thibodeaux are on the road again . . .

"Boudreaux, we have to get this shipment of mudbugs to Baton Rouge by tonight!"

"Don't worry, Thibodeaux, I already checked ahead. There are three underpasses and our 18-wheeler will fit through all of them, so just keep that motor running!"

"We're not going to make it, I say!"

So, which is it: will there be a very messy accident on Interstate 10, or is Thibodeaux just letting the sound of his own wheels drive him crazy?

 
Input
Input to this problem will consist of a single data set. The data set will be formatted according to the following description.

The data set will consist of a single line containing 3 numbers, separated by single spaces. Each number represents the height of a single underpass in inches. Each number will be between 0 and 300 inclusive.

 
Output
There will be exactly one line of output. This line will be:

NO CRASH

if the height of the 18-wheeler is less than the height of each of the underpasses, or:

CRASH X

otherwise, where X is the height of the first underpass in the data set that the 18-wheeler is unable to go under (which means its height is less than or equal to the height of the 18-wheeler). 
The height of the 18-wheeler is 168 inches.

 
Sample Input
180 160 170
 
Sample Output
CRASH 160
 
 
分析:无脑判断。
 
 #include<cstdio>
#include<cstring>
#include<cstdlib>
#include<iostream>
using namespace std;
int main()
{
int a,b,c;
scanf("%d%d%d",&a,&b,&c);
if(a<=) printf("CRASH %d\n",a);
else if(b<=) printf("CRASH %d\n",b);
else if(c<=) printf("CRASH %d\n",c);
else printf("NO CRASH\n");
return ;
}

HDU-1037(水水水题)的更多相关文章

  1. HDU-1042-N!(Java大法好 &amp;&amp; HDU大数水题)

    N! Time Limit: 10000/5000 MS (Java/Others)    Memory Limit: 262144/262144 K (Java/Others) Total Subm ...

  2. Dijkstra算法---HDU 2544 水题(模板)

    /* 对于只会弗洛伊德的我,迪杰斯特拉有点不是很理解,后来发现这主要用于单源最短路,稍稍明白了点,不过还是很菜,这里只是用了邻接矩阵 套模板,对于邻接表暂时还,,,没做题,后续再更新.现将这题贴上,应 ...

  3. 2013腾讯编程马拉松||HDU 4505 小Q系列故事——电梯里的爱情 水水水

    http://acm.hdu.edu.cn/showproblem.php?pid=4505 题目大意: 电梯最开始在0层,并且最后必须再回到0层才算一趟任务结束.假设在开始的时候已知电梯内的每个人要 ...

  4. HDU 5391 水题。

    E - 5 Time Limit:1500MS     Memory Limit:262144KB     64bit IO Format:%I64d & %I64u Submit Statu ...

  5. hdu 1544 水题

    水题 /* * Author : ben */ #include <cstdio> #include <cstdlib> #include <cstring> #i ...

  6. HDU排序水题

    1040水题; These days, I am thinking about a question, how can I get a problem as easy as A+B? It is fa ...

  7. hdu 2710 水题

    题意:判断一些数里有最大因子的数 水题,省赛即将临近,高效的代码风格需要养成,为了简化代码,以后可能会更多的使用宏定义,但是通常也只是快速拿下第一道水题,涨自信.大部分的代码还是普通的形式,实际上能简 ...

  8. hdu 5162(水题)

    题目链接: http://acm.hdu.edu.cn/showproblem.php?pid=5162 题解:看了半天以为测试用例写错了.这题玩文字游戏.它问的是当前第i名是原数组中的第几个. #i ...

  9. hdu 3357 水题

    题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=3357 #include <cstdio> #include <cmath> # ...

随机推荐

  1. spring-data-redis --简单的用spring-data-redis

    spring-data-redis序列化策略 spring-data-redis提供了多种serializer策略,这对使用jedis的开发者而言,实在是非常便捷.sdr提供了4种内置的seriali ...

  2. 【转】基于Ubuntu 14.04 LTS编译Android4.4.2源代码

    原文网址:http://blog.csdn.net/gobitan/article/details/24367439 基于Ubuntu 14.04 LTS编译Android4.4.2源代码       ...

  3. web前端相关的书籍

    一.Javascript方面的书籍: 1 JavaScript权威指南(第6版):号称javascript圣经,前端必备:前端程序员学习核心JavaScript语言和由Web浏览器定义的JavaScr ...

  4. android学习——activity的生命周期

    Android中主要组件之Activity的生命周期,基本都是翻译Android API和个人的理解. 首先看一下Android api中所提供的Activity生命周期图: Activity其实是继 ...

  5. TFS2010中文版安装

    VS2010的中文版出来一段时间了,对TFS2010的了解,也有一段时间了,只不过中文版还是首次见到.于是把第一次安装的图片分享出来,公供参数. TFS2010安装环境是操作系统为Windows Se ...

  6. 如何实现批处理文件传参数给SQLPLUS

    原文地址:http://www.cnblogs.com/HondaHsu/archive/2012/11/23/2784094.html 第一:批处理文件drop_table.bat 说明: 批处理中 ...

  7. [hadoop转载]tearsort

        1TB排序通常用于衡量分布式数据处理框架的数据处理能力.Terasort是Hadoop中的的一个排序作业,在2008年,Hadoop在1TB排序基准评估中赢得第一名,耗时209秒.那么Tera ...

  8. gcc 的visibility 使用

    gcc 的visibility 使用(zz) -fvisibility=default|internal|hidden|protectedgcc的visibility是说,如果编译的时候用了这个属性, ...

  9. __attribute__机制介绍 (转)

    1. __attribute__ GNU C的一大特色(却不被初学者所知)就是__attribute__机制. __attribute__可以设置函数属性(Function Attribute).变量 ...

  10. ReactiveCocoa框架学习2

    昨天内容回顾 信号类:表示有数据产生,信号类不发送数据 注意:不同的信号,订阅方式不同 RACSignal 创建RACDynamicSignal信号 -> didSubscribe(block) ...