MZL's chemistry
Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others)Total Submission(s): 385 Accepted Submission(s): 314
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
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
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<cstring>
#include<algorithm>
#include<cstdio>
using namespace std;
double res[100]={
0,
1312.0,
2372.3,
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
};
int main(){
int n,m;
res[35] = 1139.9;
res[36] = 1350.8;
res[53] = 1008.4;
res[54] = 1170.4;
res[85] = 890;
res[86] = 1037;
while(cin>>n>>m){
if(res[n] > res[m]) puts("FIRST BIGGER");
else puts("SECOND BIGGER");
}
return 0;
}
化学元素电离能比较

本文介绍了一种通过原子序数快速比较两种化学元素第一电离能大小的方法,并提供了一个直接输出结果的示例程序。
1917

被折叠的 条评论
为什么被折叠?



