QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#90898#5660. Simplified Genome TranslationMr_EightAC ✓21ms8136kbPython31.2kb2023-03-26 02:27:522023-03-26 02:27:53

Judging History

你现在查看的是最新测评结果

  • [2023-08-10 23:21:45]
  • System Update: QOJ starts to keep a history of the judgings of all the submissions.
  • [2023-03-26 02:27:53]
  • 评测
  • 测评结果:AC
  • 用时:21ms
  • 内存:8136kb
  • [2023-03-26 02:27:52]
  • 提交

answer

to={}
to['UUU']='F'
to['UUC']='F'
to['UUA']='L'
to['UUG']='L'
to['CUU']='L'
to['CUC']='L'
to['CUA']='L'
to['CUG']='L'
to['AUU']='I'
to['AUC']='I'
to['AUA']='I'
to['AUG']='M'
to['GUU']='V'
to['GUC']='V'
to['GUA']='V'
to['GUG']='V'
to['UCU']='S'
to['UCC']='S'
to['UCA']='S'
to['UCG']='S'
to['AGU']='S'
to['AGC']='S'
to['CCU']='P'
to['CCC']='P'
to['CCA']='P'
to['CCG']='P'
to['ACU']='T'
to['ACC']='T'
to['ACA']='T'
to['ACG']='T'
to['GCU']='A'
to['GCC']='A'
to['GCA']='A'
to['GCG']='A'
to['UAU']='Y'
to['UAC']='Y'
to['CAU']='H'
to['CAC']='H'
to['CAA']='Q'
to['CAG']='Q'
to['AAU']='N'
to['AAC']='N'
to['AAA']='K'
to['AAG']='K'
to['GAU']='D'
to['GAC']='D'
to['GAA']='E'
to['GAG']='E'
to['UGU']='C'
to['UGC']='C'
to['UGG']='W'
to['CGU']='R'
to['CGC']='R'
to['CGA']='R'
to['CGG']='R'
to['AGA']='R'
to['AGG']='R'
to['GGU']='G'
to['GGC']='G'
to['GGA']='G'
to['GGG']='G'
to['UAA']='STOP'
to['UAG']='STOP'
to['UGA']='STOP'
T=int(input())
for case in range(0,T):
    s=input()
    t=""
    for i in range(0,len(s),3):
        #print(i)
        t+=to[s[i:i+3]]
        if(t[-4:]=="STOP"):
            t=t[:-4]
            break
    print(t)

详细

Test #1:

score: 100
Accepted
time: 8ms
memory: 7972kb

input:

5
UUUUAACACUUUAUCACUUAACACCAC
CAAAAUAUGAAAAAU
AUGUACUUUGCGUUUCACUAA
UUGCACUACUAC
UACGUGGGUAUC

output:

F
QNMKN
MYFAFH
LHYY
YVGI

result:

ok 5 lines

Test #2:

score: 0
Accepted
time: 21ms
memory: 8000kb

input:

50
GGUCAGAGGGAGGGCCUAUUGAUACGUAGUGGACUAUCAUGUUCGUGAGCAGCAUGCAGAUUACCCGUUCGGCGAGGGAGAGCCCGCUCCGAAAUGUUUAGGGAGAUAGCGGGCCACAUAGUCGCUUGAGUGCAUACUGCGUACUUUAUGUACAAGUCCCGU
AAUGGAUCACUCCUCUAUCAUUUCACUAGGUGUGACACAUGAUAUACUAACGUUCUGAAUUGGCAGUGGGGUAUGAGGCACUGAUUGGUCAUGGGACAGACUUGAGAGGAGUUGUCCUUGCUAAGCCCCGUCCC...

output:

GQREGLLIRSGLSCS
NGSLLYHFTRCDT
DASYKADEGLMFVLKDTGDYGSDYWQK
SRKVLVDRISEPLVVAYLEGTDVDGANIGSKFDGANSSAWT
FACST
LTNARTSFYALRFKDACKYTCKSLFELFSNRGQFS
II
VLLRAARISCTFIHCRCSRRGFGPLSPCPPRPLAGVGSMIYNSCYIY
TRKLSFS
ESDQC
QNGIPKKAC
PHTRRTLPPSV
GI
ATSNVCTSFHGAGASGRNVCIRGRDRPL
AF
NPFQVSRSLQPRS
IHPGYLRTGGGFRSILSVTRDG...

result:

ok 50 lines

Test #3:

score: 0
Accepted
time: 13ms
memory: 8136kb

input:

50
GGUCAGAGGGAGGGCCUAUUGAUACGUAGUGGACUAUCAUGUUCGUGAGCAGCAUGCAGAUUACCCGUUCGGCGAGGGAGAGCCCGCUCCGAAAUGUUUAGGGAGAUAGCGGGCCACAUAGUCGCUUGAGUGCAUACUGCGUACUUUAUGUACAAGUCCCGU
AAUGGAUCACUCCUCUAUCAUUUCACUAGGUGUGACACAUGAUAUACUAACGUUCUGAAUUGGCAGUGGGGUAUGAGGCACUGAUUGGUCAUGGGACAGACUUGAGAGGAGUUGUCCUUGCUAAGCCCCGUCCC...

output:

GQREGLLIRSGLSCS
NGSLLYHFTRCDT
DASYKADEGLMFVLKDTGDYGSDYWQK
SRKVLVDRISEPLVVAYLEGTDVDGANIGSKFDGANSSAWT
FACST
LTNARTSFYALRFKDACKYTCKSLFELFSNRGQFS
II
VLLRAARISCTFIHCRCSRRGFGPLSPCPPRPLAGVGSMIYNSCYIY
TRKLSFS
ESDQC
QNGIPKKAC
PHTRRTLPPSV
GI
ATSNVCTSFHGAGASGRNVCIRGRDRPL
AF
NPFQVSRSLQPRS
IHPGYLRTGGGFRSILSVTRDG...

result:

ok 50 lines