F.A.Q
Hand In Hand
Online Acmers
Problem Archive
Realtime Judge Status
Authors Ranklist
 
     C/C++/Java Exams     
ACM Steps
Go to Job
Contest LiveCast
ICPC@China
Best Coder beta
VIP | STD Contests
    DIY | Web-DIY beta
Author ID 
Password 
 Register new ID

ZYB's Biology

Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 131072/131072 K (Java/Others)
Total Submission(s): 1272    Accepted Submission(s): 968


Problem Description
After getting $600$ scores in $NOIP$ $ZYB(ZJ-267)$ begins to work with biological questions.Now he give you a simple biological questions:
he gives you a $DNA$ sequence and a $RNA$ sequence,then he asks you whether the $DNA$ sequence and the $RNA$ sequence are
matched.

The $DNA$ sequence is a string consisted of $A,C,G,T$;The $RNA$ sequence is a string consisted of $A,C,G,U$.

$DNA$ sequence and $RNA$ sequence are matched if and only if $A$ matches $U$,$T$ matches $A$,$C$ matches $G$,$G$ matches $C$ on each position.
 

Input
In the first line there is the testcase $T$.

For each teatcase:

In the first line there is one number $N$.

In the next line there is a string of length $N$,describe the $DNA$ sequence.

In the third line there is a string of length $N$,describe the $RNA$ sequence.

$1 \leq T \leq 10$,$1 \leq N \leq 100$
 

Output
For each testcase,print $YES$ or $NO$,describe whether the two arrays are matched.
 

Sample Input
2 4 ACGT UGCA 4 ACGT ACGU
 

Sample Output
YES NO
 

Source
 

Statistic | Submit | Discuss | Note
Hangzhou Dianzi University Online Judge 3.0
Copyright © 2005-2024 HDU ACM Team. All Rights Reserved.
Designer & Developer : Wang Rongtao LinLe GaoJie GanLu
Total 0.000000(s) query 1, Server time : 2024-11-22 15:24:36, Gzip enabled