hdu_1037_Keep on Truckin'_201311021600
Keep on Truckin'
Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others) Total Submission(s): 7174 Accepted Submission(s): 4964
"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?
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.
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.
#include <stdio.h>
int main()
{
int a,b,c;
int t=;
while(scanf("%d %d %d",&a,&b,&c)!=EOF)
{
if(t<a&&t<b&&t<c)
printf("NO CRASH\n");
else if(t>a)
printf("CRASH %d\n",a);
else if(t>b)
printf("CRASH %d\n",b);
else
printf("CRASH %d\n",c);
}
return ;
}
hdu_1037_Keep on Truckin'_201311021600的更多相关文章
- HDU 1037 - Keep on Truckin'
没啥可说的... #include <iostream> using namespace std; ; int a,b,c; int main() { while(cin>>a ...
- hdoj-1037-Keep on Truckin'(水题)
题目链接 /* 题意:三个通道,如果比168低,那么过不去,输出最先碰到的低的通道高度值 */ #include <iostream> using namespace std; int ...
- 杭电ACM分类
杭电ACM分类: 1001 整数求和 水题1002 C语言实验题——两个数比较 水题1003 1.2.3.4.5... 简单题1004 渊子赛马 排序+贪心的方法归并1005 Hero In Maze ...
- 《Soft Skill》一书中的好句子
The biggest mistake that you can make is to believe that you are working for somebody else. Job secu ...
- HDU-1037(水水水题)
Keep on Truckin' Problem Description Boudreaux and Thibodeaux are on the road again . . . "Boud ...
- HOJ题目分类
各种杂题,水题,模拟,包括简单数论. 1001 A+B 1002 A+B+C 1009 Fat Cat 1010 The Angle 1011 Unix ls 1012 Decoding Task 1 ...
- 算法之路 level 01 problem set
2992.357000 1000 A+B Problem1214.840000 1002 487-32791070.603000 1004 Financial Management880.192000 ...
- 【转】POJ百道水题列表
以下是poj百道水题,新手可以考虑从这里刷起 搜索1002 Fire Net1004 Anagrams by Stack1005 Jugs1008 Gnome Tetravex1091 Knight ...
- 转载:hdu 题目分类 (侵删)
转载:from http://blog.csdn.net/qq_28236309/article/details/47818349 基础题:1000.1001.1004.1005.1008.1012. ...
随机推荐
- Ruby 离奇方法
send https://ref.xaio.jp/ruby/classes/object/send find https://ref.xaio.jp/ruby/classes/enumerable/f ...
- 谈谈windows下克隆的坑
本来在mac里一个项目里新建了一个I/O的文件夹. 当时就直接被系统自动改成了I:O. 本来也没多在意,感觉也不是什么大事. 这是push到GitHub上的样子. 当时没多想,感觉没什么问题,就是 ...
- 基于Spark Streaming预测股票走势的例子(一)
最近学习Spark Streaming,不知道是不是我搜索的姿势不对,总找不到具体的.完整的例子,一怒之下就决定自己写一个出来.下面以预测股票走势为例,总结了用Spark Streaming开发的具体 ...
- 推荐给Web前端开发人员的一些书籍(从基础到架构阶段)
有很多人问我说作为一个前端开发人员都需要看一些什么书籍,尤其是刚入门的新手,今天我整理了一下推荐给大家,大佬绕过. HTML+CSS+JavaScript 网页设计 从入门到精通 作为一个前端新手,强 ...
- centos安装 memcached
.安装 yum -y update yum install -y libevent libevent-devel yum install -y memcached 2.配置 vi /etc/sysco ...
- applicationContext.xml配置AOP切面编程
Computer.java package com.wh.aop2; public class Computer { public void play01(){ System.out.println( ...
- H5 标签属性、input属性
高亮文字: 全部商品只要<mark>6.18</mark> 结果: 加拼音文字: <ruby>變<rt>bian</rt></ ...
- ajax不执行success的问题
有时候经常会遇到ajax请求后台,然后后台返回数据后,不触发ajax的success函数的问题,归根到底,这与ajax的参数设置dataType和后台的返回值的类型有关,现总结如下: 一.后台返回值的 ...
- 【技术累积】【点】【java】【25】Orderd
基础概念 Orderd是spring core中定义的一个接口,使用它以及相关的Comparator和@Order注解,可以实现对元素的排序. @Order 直接先说下@Order注解吧,使用场景较多 ...
- 如何将工程推到github上
首先,读一下这个 Git-Pro中文版 步骤: 在本地文件系统中 git init 在github中新建项目(光新建就行了) 然后,出现下面这张图,打开sourceTree,按照上面的操作进行就行了. ...