首页 > 其他 > 详细

HDU-5347 MZL's chemistry

时间:2015-08-05 12:27:14      阅读:184      评论:0      收藏:0      [点我收藏+]

 http://acm.hdu.edu.cn/showproblem.php?pid=5347

MZL‘s chemistry

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


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 xy技术分享
 

 

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
 

 

Source
#include <iostream>
#include <cstdio>
#include <cstring>
#include <algorithm>
#define Max(a,b) (a>b?a:b)
#define Min(a,b) (a<b?a:b)
using namespace std;
double s[111]={0,1312,2372.3,520.2,932,800.6,
1086.5,1402.3,1313.9,1681,2080.7,495.8,737.7,
577.5,786.5,1011.8,999.6,1251.2,1520.6
};
int main()
{
    int i,j,k,l;
    s[35]=1139.9;
    s[36]=1350.8;
    s[53]=1008.4;
    s[54]=1170.4;
    s[85]=920;
    s[86]=1037;
    while(scanf("%d%d",&i,&j)!=EOF)
    {
        if(s[i]>s[j])puts("FIRST BIGGER");
        else puts("SECOND BIGGER");
    }
    return 0;
}

 

HDU-5347 MZL's chemistry

原文:http://www.cnblogs.com/cancangood/p/4703997.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!