转载请注明出处: http://www.cnblogs.com/fraud/          ——by fraud

MZL's chemistry

Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/65536 K (Java/Others)
Total Submission(s): 373    Accepted Submission(s): 310

Problem Description
MZL define F(X) as the first ionization energy of the chemical element X

Now he get two chemical elements U,V,given as their atomic number,he wants to compare F(U) and F(V)

It is guaranteed that atomic numbers belongs to the given set:{1,2,3,4,..18,35,36,53,54,85,86}

It is guaranteed the two atomic numbers is either in the same period or in the same group

It is guaranteed that x≠y

 



Input
There are several test cases

For each test case,there are two numbers u,v,means the atomic numbers of the two element

 



Output
For each test case,if F(u)>F(v),print "FIRST BIGGER",else print"SECOND BIGGER"
 



Sample Input
1 2
5 3
 



Sample Output
SECOND BIGGER
FIRST BIGGER

百度第一电离能,然后打个表就好

 /**
* code generated by JHelper
* More info: https://github.com/AlexeyDmitriev/JHelper
* @author xyiyy
*/ #include <iostream>
#include <fstream> //#####################
//Author:fraud
//Blog: http://www.cnblogs.com/fraud/
//#####################
//#pragma comment(linker, "/STACK:102400000,102400000")
#include <iostream>
#include <sstream>
#include <ios>
#include <iomanip>
#include <functional>
#include <algorithm>
#include <vector>
#include <string>
#include <list>
#include <queue>
#include <deque>
#include <stack>
#include <set>
#include <map>
#include <cstdio>
#include <cstdlib>
#include <cmath>
#include <cstring>
#include <climits>
#include <cctype> using namespace std; double f[] = {1312.0, 2372.0, 520.2, 899.5, 800.6,
1086.5, 1402.3, 1313.9, 1681.0, 2080.7,
495.8, 737.7, 577.5, 786.5, 1011.8,
999.6, 1251.2, 1520.6, 418.8, 589.8,
633.1, 658.8, 650.9, 652.9, 717.3,
762.5, 760.4, 737.1, 745.5, 906.4,
578.8, , , , 1139.9,
1350.8, , 549.5, , 640.1,
652.1, 684.3, , 710.2, 719.7,
804.4, 731.0, 867.8, 558.3, 708.6,
, 869.3, 1008.4, 1170.4, 375.7}; double gao(int x) {
if (x == )return ;
if (x == )return ;
return f[x - ];
} class hdu5347 {
public:
void solve(std::istream &in, std::ostream &out) {
int a, b;
while (in >> a >> b) {
double x = gao(a);
double y = gao(b);
if (x > y) out << "FIRST BIGGER" << endl;
else out << "SECOND BIGGER" << endl;
}
}
}; int main() {
std::ios::sync_with_stdio(false);
std::cin.tie();
hdu5347 solver;
std::istream &in(std::cin);
std::ostream &out(std::cout);
solver.solve(in, out);
return ;
}

hdu5347 MZL's chemistry(打表)的更多相关文章

  1. HDU-5347 MZL's chemistry

    http://acm.hdu.edu.cn/showproblem.php?pid=5347 MZL's chemistry Time Limit: 2000/1000 MS (Java/Others ...

  2. HDU 5347(MZL&#39;s chemistry-打表)

    MZL's chemistry Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/65536 K (Java/Others) ...

  3. JSP表单处理

    当需要通过从浏览器获取一些信息,在许多情况下,最终给到Web服务器后台程序.浏览器使用两种方法将这些信息传递给Web服务器.这些方法是GET方法和POST方法. GET 方法: GET方法将追加到页面 ...

  4. 解决Oracle 11g在用EXP导出时,空表不能导出

    实践结论可行,看"2.解决办法" 一.问题原因:     11G中有个新特性,当表无数据时,不分配segment,以节省空间     1.insert一行,再rollback就产生 ...

  5. 【转载】springMVC表单校验+全注解

    在这篇文章中,我们将学习如何使用Spring表单标签, 表单验证使用 JSR303 的验证注解,hibernate-validators,提供了使用MessageSource和访问静态资源(如CSS, ...

  6. Hive案例05-学生成绩表综合案例

    1. 数据说明 (1) student表 hive> select * from student; # 学生ID 学生姓名 性别 年龄 所在系 # sid sname sex age dept ...

  7. oracle 11G 导出空表失败的解决方法

    一.问题原因:     11G中有个新特性,当表无数据时,不分配segment,以节省空间     1.insert一行,再rollback就产生segment了. 该方法是在在空表中插入数据,再删除 ...

  8. JSP 表单处理

    JSP 表单处理 我们在浏览网页的时候,经常需要向服务器提交信息,并让后台程序处理.浏览器中使用 GET 和 POST 方法向服务器提交数据. GET 方法 GET方法将请求的编码信息添加在网址后面, ...

  9. 2015 Multi-University Training Contest 5 1009 MZL's Border

    MZL's Border Problem's Link: http://acm.hdu.edu.cn/showproblem.php?pid=5351 Mean: 给出一个类似斐波那契数列的字符串序列 ...

随机推荐

  1. Mysql 储存过程以及 python callproc调用

    一.存储过程(stored procedure) 存储过程将存入的一系列SQL语句进行预编译,执行并存放在数据库中,之后如果需要使用sql语句对这一组sql进行访问时可以直接提取(很好理解 存储过程就 ...

  2. 使用Android平板编程,执行linux命令

    android有一些应用支持开发, AIDE 介绍http://www.wandoujia.com/apps/com.aide.ui https://play.google.com/store/app ...

  3. Hadoop学习历程(三、第一个程序)

    根据之前的操作,我们已经可以正常的启动Hadoop了,关于真正的集群我会在之后进行说明.现在我们来看一下第一个程序吧 1. 在eclipse上建立一个java项目 2. 将 /usr/hadoop/s ...

  4. objc runtime 动态增加属性

    objective-c中,有类别可以在不修改源码的基础上增加方法:近排在看别人的开源代码时,发现还可以动态增加属性.而且是在运行时,太牛B了. 使用运行时库,必须要先引入 objc/runtime.h ...

  5. JavaScript中String对象处理HTML标记中文本的方法

    big():创建一个<big></big>标记,将这个字符串的字体变大blink():创建一个<blink></blink>标记,使字符串具有闪烁效果b ...

  6. 智能卡安全机制比较系列(二)DS SmartCard

    DS Smart Card是飞利浦公司自己开发的一款CPU卡产品,在早期芯片厂商开发自己的COS并进行推广很普遍,现在像英飞凌(前西门子半导体)以及恩智普(前飞利浦半导体)几乎很少推广自己的COS,大 ...

  7. HTTP断点续传(分块传输)(HTTP头格式非常清楚)

    简述 断点续传:指的是在上传/下载时,将任务(一个文件或压缩包)人为的划分为几个部分,每一个部分采用一个线程进行上传/下载,如果碰到网络故障,可以从已经上传/下载的部分开始继续上传/下载未完成的部分, ...

  8. inux xsel 拷贝复制命令行输出放在系统剪贴板上

    转载自:http://oldratlee.com/post/2012-12-23/command-output-to-clip 为什么要这么做?直接把命令的输出(比如 grep/awk/sed/fin ...

  9. osip及eXosip的编译方法

    osip及eXosip的编译方法 在最新版本的osip2.exosip2中不支持在VC6.0下编译osip.exosip协议栈的方法 说明: 1.以下文章中的osip版本为3.1.0 2.eXosip ...

  10. sicily 1099 Packing Passengers

    /****  题意:  求x,y 满足 x*pa+y*pb=n 同时使得 p = x*ca+y*cb的值最小,若有多种可能,则选择最大x值的组合**  分析:  x*pa+y*pb=n 可以用 线性同 ...