QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#731919 | #7070. Isomerism | Yurily# | WA | 79ms | 4004kb | C++20 | 1.2kb | 2024-11-10 12:16:56 | 2024-11-10 12:17:04 |
Judging History
answer
#include<iostream>
#include<cstdio>
#include<cstring>
#include<cmath>
#include<algorithm>
#include<string>
#include<map>
using namespace std;
const int N = 4;
const int M = 8;
string ba[M + 3] = {"-F", "-Cl", "-Br", "-I", "-CH3", "-CH2CH3", "-CH2CH2CH3", "-H"};
map<string, int>rk;
string R[N +3];
int r[N + 3];
void sol(){
for(int i = 1; i <= N; i++){
cin >> R[i];
r[i] = rk[R[i]];
}
if(r[1] == r[3] || r[2] == r[4]){
printf("None\n");
return ;
}
if(r[1] == r[2] || r[3] == r[4]){
printf("Cis\n");
return ;
}
if(r[1] == r[4] || r[2] == r[3]){
printf("Trans\n");
return ;
}
if(r[1] < r[3] && r[1] < r[4] && r[2] < r[3] && r[2] < r[4]){
printf("Zasamman\n");
return ;
}
if(r[3] < r[1] && r[3] < r[2] && r[4] < r[1] && r[4] < r[2]){
printf("Zasamman\n");
return ;
}
printf("Entgegen\n");
}
int main(){
rk.clear();
for(int i = 0; i < M; i++)
rk[ba[i]] = i;
int T;
scanf("%d\n", &T);
while(T--)
sol();
return 0;
}
詳細信息
Test #1:
score: 100
Accepted
time: 0ms
memory: 4004kb
input:
2 -H -H -H -Cl -F -F -Br -Cl
output:
None Cis
result:
ok 2 lines
Test #2:
score: -100
Wrong Answer
time: 79ms
memory: 3792kb
input:
100000 -Br -CH3 -H -CH2CH2CH3 -CH3 -I -Cl -Cl -CH3 -Br -CH2CH3 -CH3 -H -CH3 -Cl -CH3 -H -F -CH2CH3 -CH2CH2CH3 -Br -Br -Cl -CH2CH2CH3 -F -Cl -H -CH2CH2CH3 -CH2CH2CH3 -CH3 -CH3 -H -CH2CH2CH3 -CH3 -CH2CH2CH3 -Br -CH3 -Cl -CH2CH2CH3 -CH3 -H -CH2CH3 -I -I -CH3 -Cl -Br -I -I -Cl -H -F -CH2CH2CH3 -Cl -Br -...
output:
Zasamman Cis Trans None Entgegen Cis Zasamman Trans None Trans Cis Entgegen Entgegen Cis Cis Entgegen Trans None Cis None Cis None None Zasamman Cis None Entgegen Entgegen None None Cis Trans Zasamman Entgegen Zasamman Trans Entgegen None Zasamman Trans Cis Trans Zasamman Trans None Zasamman None Tr...
result:
wrong answer 51st lines differ - expected: 'Zasamman', found: 'Entgegen'