Problem:
 Score : 100 points    Problem Statement On the Planet AtCoder, there are four types of bases: A , C , G and T . A bonds with T , and C bonds with G .  You are given a letter b as input, which is A , C , G or T . Write a program that prints the letter representing the base that bonds with the base b .      Constraints  b is one of the letters A , C , G and T .         Input Input is given from Standard Input in the following format:  b       Output Print the letter representing the base that bonds with the base b .        Sample Input 1 A      Sample Output 1 T       Sample Input 2 G      Sample Output 2 C

Solution (Python):
b = input()
number1 = ['A','T']
number2 = ['C','G']
print(number1[number1.index(b)-1]) if b in number1 else print(number2[number2.index(b)-1])

Solution (Python):
b = input()

if b=='A':
    print('T')
elif b=='T':
    print('A')
elif b=='C':
    print('G')
elif b=='G':
    print('C')

Solution (Python):
S=input()

if S=="A":
  print("T")
if S=="T":
  print("A")
if S=="C":
  print("G")
if S=="G":
  print("C")

Solution (Python):
b=input()
if b=="A":
    print("T")
elif b=="T":
    print("A")
elif b=="G":
    print("C")
else:
    print("G")

Solution (Python):
x = input()
if x == "A":
    print("T")
elif x == "T":
    print("A")
elif x == "G":
    print("C")
else:
    print("G")

Solution (Python):
s=input()
if s=='A':
  print('T')
elif s=='C':
  print('G')
elif s=='G':
  print('C')
elif s=='T':
  print('A')

Solution (Python):
b=input()
d={'A':'T','T':'A','C':'G','G':'C'}
print(d[b])

Solution (Python):
b = input()
print("A" if b == "T" else "T" if b == "A" else "C" if b == "G" else "G")

Solution (Python):
b=input()
if b=='A':
    print('T')
if b=='T':
    print('A')
if b=='G':
    print('C')
if b=='C':
    print('G')

Solution (Python):
b = str(input())
if b == "A":
  print("T")
elif b == "T":
  print("A")
elif b == "C":
  print("G")
else:
  print("C")

Solution (Python):
ans = {
    "A": "T",
    "C": "G",
    "G": "C",
    "T": "A",
}
print(ans[input()])

Solution (Python):
b = input()
if b == "A":
  print("T")
elif b == "C":
  print("G")
elif b == "G":
  print("C")
else:
  print("A")

Solution (Python):
S=lambda:input()
I=lambda:int(input())
L=lambda:list(map(int,input().split()))
LS=lambda:list(map(str,input().split()))

b=S()
pair={'A':'T','C':'G','G':'C','T':'A'}
print(pair[b])

Solution (Python):
b = input()
if b == 'A':
    print('T')
elif b == ('T'):
    print('A')
elif b == ('C'):
    print('G')
else:
    print('C')

Solution (Python):
b=input()

if b=='A':
    print('T')
elif b=='C':
    print('G')
elif b=='T':
    print('A')
else:
    print('C')

Solution (Python):
b=input()
if b=='A':
    print('T')
elif b=='T':
    print('A')
elif b=='C':
    print('G')
elif b=='G':
    print('C')

Solution (Python):
b=input()
if b=="A":
    print("T")
elif b=="G":
    print("C")
elif b=="C":
    print("G")
else:
    print("A")

Solution (Python):

b = input()
if b == 'A':
    print('T')
elif b == "T":
    print("A")
elif b == "C":
    print("G")
elif b == "G":
    print("C")

Solution (Python):
b = input()
if b == "A":
    print("T")
elif b == "T":
    print("A")
elif b == "G":
    print("C")
else:
    print("G")

Solution (Python):

b=input()
d = dict([('A', 'T'), ('C', 'G'), ('G', 'C'), ('T', 'A')])
print(d[b])

Solution (Python):

b = input()


heilx = {
    "A": "T",
    "T": "A",
    "C": "G",
    "G": "C"
}
print(heilx[b])

Solution (Python):
b = str(input())
if b == "A":
	print("T")
elif b == "T":
	print("A")
elif b == "C":
	print("G")
elif b == "G":
	print("C")

Solution (Python):
c=input()
print('A' if c=='T' else 'T' if c=='A' else 'C' if c== 'G' else 'G')

Solution (Python):
b=input()
if b=="A":
    print("T")
elif b=="T":
    print("A")
elif b=="C":
    print("G")
else:
    print("C")

Solution (Python):
b= input()

if b =='A':
    print('T')
elif b=='T':
    print('A')
elif b=='C':
    print('G')
else:
    print('C')

Solution (Python):
base = ["A", "C", "G", "T", "G", "C", "A"] 
b = input()
print(base[base.index(b)+3])

Solution (Python):
b = input()

bp = {'A': 'T', 'T': 'A', 'C': 'G', 'G': 'C'}
print(bp[b])

Solution (Python):
print('TAGC'['ATCG'.find(input())])

Solution (Python):
b = input().rstrip()
t = {'A': 'T', 'T': 'A', 'C': 'G', 'G': 'C'}
print(t[b])

Solution (Python):
letter = input()

dict = {'A': 'T', 'C':'G', 'T':'A', 'G':'C'}
if letter in dict:
  print(dict[letter])

Solution (Python):
b = input()
if b == 'A':
    print('T')
elif b == 'T':
    print('A')
elif b == 'C':
    print('G')
else:
    print('C')

Solution (Python):
b = input()
print("A" if b == "T" else "T" if b == "A" else
      "C" if b == "G" else "G")

Solution (Python):
b=input()
if b=="A":
    print("T")
elif b=="C":
    print("G")
elif b=="T":
    print("A")
elif b=="G":
    print("C")

Solution (Python):
b = input()

convert = {
    "A": "T",
    "T": "A",
    "C": "G",
    "G": "C"
          }

print(convert[b])

Solution (Python):
b = input()

def tog(s):
    if s=="A":
        return "T"
    elif s=="T":
        return "A"
    elif s=="C":
        return "G"
    elif s=="G":
        return "C"
    else:
        return None

print(tog(b))

Solution (Python):
import itertools
import math
import fractions
import functools
import copy
b = input()
if b == "A":
    print("T")
if b == "T":
    print("A")
if b == "C":
    print("G")
if b == "G":
    print("C")

Solution (Python):
b = input()
if b == 'A':
    print('T')
elif b == 'T':
    print('A')
elif b == 'C':
    print('G')
elif b == 'G':
    print('C')

Solution (Python):
b=input()

if b=='A':
  print('T')
elif b=='T':
  print('A')
elif b=='C':
  print('G')
else:
  print('C')

Solution (Python):
b = input()
print('A' if b == 'T' else 'T' if b == 'A' else 'C' if b == 'G' else 'G')

Solution (Python):


import sys






















def main():
    mod = 1000000007                
    inf = float('inf')              
    
    sys.setrecursionlimit(10**6)    
    def input(): return sys.stdin.readline().rstrip()
    def ii():    return int(input())
    def mi():    return map(int, input().split())
    def mi_0():  return map(lambda x: int(x)-1, input().split())
    def lmi():   return list(map(int, input().split()))
    def lmi_0(): return list(map(lambda x: int(x)-1, input().split()))
    def li():    return list(input())
    
    
    b = input()
    table = str.maketrans({'A':'T', 'T':'A', 'C':'G', 'G':'C'})
    print(b.translate(table))

if __name__ == "__main__":
    main()

Solution (Python):
dict = {'A':'T', 'T':'A', 'G':'C', 'C':'G'}
print( dict[input()] )

Solution (Python):
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, tan, asin, acos, atan, radians, degrees, log2
from itertools import accumulate, permutations, combinations, combinations_with_replacement, product, groupby
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left
from heapq import heappush, heappop
from functools import reduce
def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def ZIP(n): return zip(*(MAP() for _ in range(n)))
import numpy as np
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

b = input()

at = ["A", "T"]
gc = ["G", "C"]

if b == "A" or b == "T":
	at.remove(b)
	print(at.pop())
else:
	gc.remove(b)
	print(gc.pop())

Solution (Python):
b = input()

if b == 'A':
    print('T')
elif b == 'T':
    print('A')
elif b == 'C':
    print('G')
else:
    print('C')

Solution (Python):
b = input()
base = ['A', 'C', 'G', 'T']
versus = ['T', 'G', 'C', 'A']

print(versus[base.index(b)])

Solution (Python):
b = input()

if b=='A':
    print('T')
elif b=='T':
    print('A')
elif b=='C':
    print('G')
elif b=='G':
    print('C')

Solution (Python):
S = input()
if S == 'A':
  print('T')
if S == 'T':
  print('A')
if S == 'G':
  print('C')
if S == 'C':
  print('G')

Solution (Python):
import bisect,collections,copy,heapq,itertools,math,string
import sys
def S(): return sys.stdin.readline().rstrip()
def M(): return map(int,sys.stdin.readline().rstrip().split())
def I(): return int(sys.stdin.readline().rstrip())
def LI(): return list(map(int,sys.stdin.readline().rstrip().split()))
def LS(): return list(sys.stdin.readline().rstrip().split())
b = S()
ans = ''
if b == 'A':
    ans = 'T'
if b == 'C':
    ans = 'G'
if b == 'G':
    ans = 'C'
if b == 'T':
    ans = 'A'
print(ans)

Solution (Python):
b=str(input())
if b=="A":
  print("T")
elif b=="T":
  print("A")
elif b==("C"):
  print("G")
else:
  print("C")

Solution (Python):
s = input()

if s=="A":
  print("T")
if s=="T":
  print("A")
if s=="C":
  print("G")
if s=="G":
  print("C")

Solution (Python):
b = input()
if b == 'A':
    print('T')
elif b == 'C':
    print('G')
elif b == 'G':
    print('C')
elif b == 'T':
    print('A')

Solution (Python):
import sys
import math
import bisect

def main():
    s = input()
    if s == 'A':
        print('T')
    elif s == 'C':
        print('G')
    elif s == 'G':
        print('C')
    elif s == 'T':
        print('A')
    
if __name__ == "__main__":
    main()

Solution (Python):
b = str(input())
if b == 'A':
    print('T')
elif b == 'C':
    print('G')
elif b == 'G':
    print('C')
else:
    print('A')

Solution (Python):
b = input()
if b == 'A':
    print('T')
    exit()
if b == 'T':
    print('A')
    exit()
if b == 'C':
    print('G')
    exit()
if b == 'G':
    print('C')
    exit()

Solution (Python):
b=input()
print("A"if b=="T" else "C"if b=="G" else "G"if b=="C" else"T")

Solution (Python):
from collections import defaultdict, deque, Counter
from heapq import heappush, heappop, heapify
from itertools import permutations, accumulate, combinations, combinations_with_replacement
from math import sqrt, ceil, floor, factorial
from bisect import bisect_left, bisect_right, insort_left, insort_right
from copy import deepcopy
from operator import itemgetter
from functools import reduce
from fractions import gcd
import sys
def input(): return sys.stdin.readline().rstrip()
def I(): return int(input())
def Is(): return map(int, input().split())
def LI(): return list(map(int, input().split()))
def TI(): return tuple(map(int, input().split()))
def IR(n): return [I() for _ in range(n)]
def LIR(n): return [LI() for _ in range(n)]
def TIR(n): return [TI() for _ in range(n)]
def S(): return input()
def Ss(): return input().split()
def LS(): return list(input())
def SR(n): return [S() for _ in range(n)]
def SsR(n): return [Ss() for _ in range(n)]
def LSR(n): return [LS() for _ in range(n)]
sys.setrecursionlimit(10**6)
MOD = 10**9+7
INF = float('inf')


b = S()
if b == 'A':
    print('T')
elif b == 'T':
    print('A')
elif b == 'G':
    print('C')
else:
    print('G')

Solution (Python):
import sys
def input(): return sys.stdin.readline().strip()


def main():
    b = input()
    if b == 'A': print('T')
    elif b == 'T': print('A')
    elif b == 'C': print('G')
    elif b == 'G': print('C')


if __name__ == "__main__":
    main()

Solution (Python):
pairs = {
    'A': 'T',
    'T': 'A',
    'C': 'G',
    'G': 'C',
}

print(pairs[input()])

Solution (Python):
b = input()
if b == 'A':
    print('T')
elif b == 'T':
    print('A')
elif b == 'C':
    print('G')
else:
    print('C')

Solution (Python):
S = input().rstrip()
d = {'A':'T','C':'G','G':'C','T':'A'}
print(d[S])

Solution (Python):
b = input()
print("A" if b == "T" else "T" if b == "A" else "G" if b == "C" else "C")

Solution (Python):
b = input()
if b == 'A':
    print('T')
elif b == 'T':
    print('A')
elif b == 'C':
    print('G')
else:
    print('C')

Solution (Python):
def ABC_122_A():
    b = input()

    if b =='A':
        print('T')
    elif b == 'T':
        print('A')
    elif b == 'C':
        print('G')
    else:
        print('C')

if __name__ == '__main__':

    ABC_122_A()

Solution (Python):
from statistics import median


from fractions import gcd
from itertools import combinations 
from collections import deque
from collections import defaultdict
import bisect










import sys
sys.setrecursionlimit(10000000)
mod = 10**9 + 7

def readInts():
  return list(map(int,input().split()))

def main():
    dic = {'A':'T','T':'A','C':'G','G':'C'}
    print(dic[input()])
if __name__ == '__main__':
  main()

Solution (Python):
b=input()
print(('A' if b=='T' else 'T') if b in ['A','T'] else ('C' if b=='G' else 'G'))

Solution (Python):
b=str(input())
if b=='A':
  print('T')
if b=='T':
  print('A')
if b=='C':
  print('G')
if b=='G':
  print('C')

Solution (Python):
def main():
    ATCG = 'ATCG'

    b = input()
    i = ATCG.index(b)
    print(ATCG[i ^ 1])


if __name__ == '__main__':
    main()

Solution (Python):
print({'A':'T','T':'A','G':'C','C':'G'}[input()])

Solution (Python):
print(['A','T','C','G'][((ord(input())+1)%5)])

Solution (Python):
b = input()
d = {'A': 'T', 'T': 'A', 'C': 'G', 'G': 'C'}
print(d[b])

Solution (Python):
b=input()
D={"A":"T","T":"A","C":"G","G":"C"}
print(D[b])

Solution (Python):
import sys
sys.setrecursionlimit(1 << 25)
read = sys.stdin.readline
ra = range
enu = enumerate


def read_ints():
    return list(map(int, read().split()))


def read_a_int():
    return int(read())


def read_tuple(H):
    '''
    H is number of rows
    '''
    ret = []
    for _ in range(H):
        ret.append(tuple(map(int, read().split())))
    return ret


def read_col(H):
    '''
    H is number of rows
    A列、B列が与えられるようなとき
    ex1)A,B=read_col(H)    ex2) A,=read_col(H) 
    '''
    ret = []
    for _ in range(H):
        ret.append(list(map(int, read().split())))
    return tuple(map(list, zip(*ret)))


def read_matrix(H):
    '''
    H is number of rows
    '''
    ret = []
    for _ in range(H):
        ret.append(list(map(int, read().split())))
    return ret
    


MOD = 10**9 + 7
INF = 2**31  

from collections import defaultdict, Counter, deque
from operator import itemgetter
from itertools import product, permutations, combinations
from bisect import bisect_left, bisect_right  

b = input()
ans = {'A': 'T',
       'T': 'A',
       'C': 'G',
       'G': 'C'}
print(ans[b])

Solution (Python):
b = input()
if b == 'A':
    print('T')
elif b == 'T':
    print('A')
elif b == 'C':
    print('G')
else:
    print('C')

Solution (Python):
import sys
def input(): return sys.stdin.readline().strip()
b=input()
n=len(b)
l=[""]*n
for i in range(n):
    if b[i]=="A":
        l[i]="T"
    if b[i]=="T":
        l[i]="A"
    if b[i]=="G":
        l[i]="C"
    if b[i]=="C":
        l[i]="G"
print(*l)

Solution (Python):
b = input()
d = dict()
d['A'] = "T"
d['T'] = 'A'
d['G'] = 'C'
d['C'] = 'G'
print(d[b])

Solution (Python):
b = input()

dic={'A':'T','T':'A','G':'C','C':'G'}
print(dic[b])

Solution (Python):
b = str(input())

if b == 'A':
    print('T')
elif b == 'T':
    print('A')
elif b == 'G':
    print('C')
elif b == 'C':
    print('G')

Solution (Python):
b = input()
d = {"A":"T", "T":"A", "C":"G", "G":"C"}
print(d[b])

Solution (Python):
D = {"A":"T","T":"A","C":"G","G":"C"}
b = input().strip()
x = ""
for i in range(len(b)):
    x += D[b[i]]
print(x)

Solution (Python):
s=input()
a=['T','G','C','A']
b=['A','C','G','T']
print(a[b.index(s)])

Solution (Python):
b = input()
if b=='A':
    print('T')
elif b=='T':
    print('A')
elif b=='C':
    print('G')
else:
    print('C')

Solution (Python):
X = input()
dic = {"A":"T","T":"A","C":"G","G":"C"}
print(dic[X])

Solution (Python):
import sys
input = sys.stdin.readline
S = input()[: -1]
t = ["A", "C", "G", "T"]
for i in range(4):
  if S == t[i]:
    print(t[-1 - i])
    exit(0)

Solution (Python):
s=input()
if s=='A':
  print('T')
elif s=='C':
  print('G')
elif s=='G':
  print('C')
else:
  print('A')

Solution (Python):
def main():
    dic = {'A':'T', 'T':'A', 'C':'G', 'G':'C'}
    print(dic[input()])

if __name__ == '__main__':
    main()

Solution (Python):
import sys
input = sys.stdin.readline
sys.setrecursionlimit(10**7)
from collections import Counter, deque
from collections import defaultdict
from itertools import combinations, permutations, accumulate, groupby, product
from bisect import bisect_left,bisect_right
from heapq import heapify, heappop, heappush
from math import floor, ceil
from operator import itemgetter
def I(): return int(input())
def MI(): return map(int, input().split())
def LI(): return list(map(int, input().split()))
def LI2(): return [int(input()) for i in range(n)]
def MXI(): return [[LI()]for i in range(n)]
def printns(x): print('\n'.join(x))
def printni(x): print('\n'.join(list(map(str,x))))
inf = 10**17
mod = 10**9 + 7

u=input().rstrip()
if u=="A":
    print("T")
elif u=="T":
    print("A")
elif u=="G":
    print("C")
else:
    print("G")

Solution (Python):
b = input()

if b == 'A': print('T')
elif b == 'T': print('A')
elif b == 'C': print('G')
else: print('C')

Solution (Python):
import sys

sys.setrecursionlimit(10 ** 7)
f_inf = float('inf')
mod = 10 ** 9 + 7


def resolve():
    b = input()

    if b == "A":
        print("T")
    elif b == "T":
        print("A")
    elif b == "C":
        print("G")
    else:
        print("C")


if __name__ == '__main__':
    resolve()

Solution (Python):
import sys
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
sys.setrecursionlimit(10 ** 7)

b = readline().rstrip().decode()
if b == 'A':
    print('T')
elif b == 'T':
    print('A')
elif b == 'G':
    print('C')
else:
    print('G')

Solution (Python):
S=input()
ans=""
for s in S:
    if s=="A":
        ans+="T"
    elif s=="T":
        ans+="A"
    elif s=="C":
        ans+="G"
    else:
        ans+="C"
print(ans)

Solution (Python):
def main():
    b = input()
    dic = {"A": "T", "T": "A", "C": "G", "G": "C"}
    print(dic[b])


if __name__ == '__main__':
    main()

Solution (Python):
b = input()
if b=="A":
    print("T")
elif b=="T":
    print("A")
elif b=="C":
    print("G")
elif b=="G":
    print("C")

Solution (Python):
b = input()
c = {'A':'T','C':'G','G':'C','T':'A'}
print(c[b])

Solution (Python):
a=input()
if a=='A':
  print('T')
elif a=='T':
  print('A')
elif a=='G':
  print('C')
elif a=='C':
  print('G')

Solution (Python):
b = input()
if (b=="A"):
    print("T")
elif (b=="T"):
    print("A")
elif (b=="C"):
    print("G")
else:
    print("C")

Solution (Python):
b = input()
dic = {"A" : "T", "T" : "A", "C" : "G", "G": "C"}

print(dic[b])

Solution (Python):
b = input()
if b =='A': print('T')
if b == 'T': print('A')
if b == 'C': print('G')
if b == 'G': print('C')

Solution (Python):
b=input()
if b=="A":
	print("T")
elif b=="T":
	print("A")
elif b=="C":
	print("G")
else:
	print("C")

Solution (Python):
b=input()
if b=="A":
    print("T")
elif b=="T":
    print("A")
elif b=="C":
    print("G")
else:
    print("C")

Solution (Python):
k = input()
m = {'A':'T','C':'G','G':'C','T':'A'}
print(m[k])

Solution (Python):
b = str(input())
if b == 'A':
    print('T')
elif b == 'T':
    print('A')
elif b == 'C':
    print('G')
elif b == 'G':
    print('C')

Solution (Python):
n=input()
if n=="A":
    print("T")
elif n=="T":
    print("A")
elif n=="C":
    print("G")
else:
    print("C")

Solution (Python):
dict = {'A':'T', 'T':'A', 'G':'C', 'C':'G'}
print(dict[input()])

Solution (Python):
x = input()
if x == "A":
    print("T")
elif x == "T":
    print("A")
elif x == "G":
    print("C")
else:
    print("G")

Solution (Python):

b = input()

print("A" if b =="T" else "T" if b == "A" else "C" if b == "G" else "G")

Solution (Python):
b = input()
if b == 'A':
    print("T")
elif b == 'C':
    print("G")
elif b == 'G':
    print("C")
elif b == 'T':
    print("A")

Solution (Python):
s=input()
if s=="A":
    print("T")
if s=="T":
    print("A")
if s=="C":
    print("G")
if s=="G":
    print("C")

Solution (Python):
s = input()
ls = ['A', 'T', 'A', 'C', 'G', 'C']
print(ls[ls.index(s)+1])

Solution (Python):
b = input()
print("A" if b=="T" else "T" if b=="A" else "G" if b=="C" else "C")

Solution (Python):
b = input()
l1 = ['A','T']
l2 = ['C','G']
if b in l1:
  l1.remove(b)
  print(l1[0])
else:
  l2.remove(b)
  print(l2[0])

Solution (Python):
b = input()
if b == 'A':
  print('T')
elif b == 'T':
  print('A')
elif b == 'G':
  print('C')
else:
  print('G')

Solution (Python):
b = str(input())
dict = {'A':'T','T':'A', 'C':'G', 'G':'C'}
print(dict[b])

Solution (Python):
dic = {'A':'T', 'T':'A', 'G':'C', 'C':'G'}
print(dic[input()])

Solution (Python):


b = input()
if b == 'A':
    print('T')
elif b == 'T':
    print('A')
elif b == 'C':
    print('G')
elif b == 'G':
    print('C')

Solution (Python):
b = input()
if b =="A":
  print("T")
elif b =="T":
  print("A")
elif b == "C":
  print("G")
else:
  print("C")

Solution (Python):
b = input()
if b == 'A' :
    print( 'T' )
elif b == 'T' :
    print( 'A' )
elif b == 'G' :
    print( 'C' )
elif b == 'C' :
    print( 'G' )

Solution (Python):
b = input()

if b == 'A' or b == 'T':
    if b == 'A':
        print('T')
    else:
        print('A')
else:
    if b == 'G':
        print('C')
    else:
        print('G')

Solution (Python):


b = input()

if b == "A":
    print("T")
elif b == "T":
    print("A")
elif b == "C":
    print("G")
elif b == "G":
    print("C")

Solution (Python):
s=input()
if s=="A":
    print("T")
elif s=="T":
    print("A")
elif s=="C":
    print("G")
elif s=="G":
    print("C")

Solution (Python):

b = input()
if b == "A":
    print("T")
if b == "C":
    print("G")
if b == "G":
    print("C")
if b == "T":
    print("A")

Solution (Python):
b=input()
if b=="A":
    print("T")
elif b=="C":
    print("G")
elif b=="G":
    print("C")
elif b=="T":
    print("A")

Solution (Python):
d = {'A': 'T', 'C': 'G', 'G': 'C', 'T': 'A'}
print(d[input()])

Solution (Python):
b_dict = {"A": "T", "C": "G", "G": "C", "T": "A"}
print(b_dict[input()])

Solution (Python):
b = input()

if b == "A": print("T")
if b == "C": print("G")
if b == "G": print("C")
if b == "T": print("A")

Solution (Python):
l = {'A':'T','T':'A','G':'C','C':'G'}
print(l[input()])

Solution (Python):
b = input()

d = {'A':'T','T':'A','C':'G','G':'C'}
print(d[b])

Solution (Python):
b=input()
print('A' if b=='T' else 'C' if b=='G' else 'G' if b=='C' else 'T')

Solution (Python):
b=input()
bl=["A",'T','G','C']
bbb=["T",'A','C','G']
a=bl.index(b)
print(bbb[a])

Solution (Python):
b = input()
if b == "A":
    print("T")
elif b == "T":
    print("A")
elif b == "G":
    print("C")
else:
    print("G")

Solution (Python):
b = input()

print('A' if b=='T' else 'T' if b=='A' else 'C' if b=='G' else 'G')

Solution (Python):
b=input()
ans=""
for i in range(len(b)):
    if b[i]=="A":
        ans+="T"
    elif b[i]=="T":
        ans+="A"
    elif b[i]=="C":
        ans+="G"
    elif b[i]=="G":
        ans+="C"
print(ans)

Solution (Python):
b = input()
lst = [["A", "T"], ["G", "C"]]
print(lst[0][lst[0].index(b) - 1]) if b in lst[0] else print(lst[1][lst[1].index(b) - 1])

Solution (Python):
base = input()
if base	== "A":
    print("T")
elif base =="T":
    print("A")
elif base =="G":
    print("C")
elif base =="C":
    print("G")

Solution (Python):
b = input()
a = {'A': 'T', 'T': 'A', 'C': 'G', 'G': 'C'}
print(a[b])

Solution (Python):
dic={"A":"T","G":"C"}
s=input()
for l,(i,j) in enumerate(dic.items()):
    if i==s:print(j)
    if j==s:print(i)

Solution (Python):


b = input()

if b == 'A':
    print('T')
elif b == 'T':
    print('A')
elif b == 'C':
    print('G')
else:
    print('C')

Solution (Python):
def double_helix(b):

    acgt = {"A":"T", "T":"A", "C":"G", "G":"C"}

    return acgt[b]
def main():
    b = str(input())
    print(double_helix(b))

if __name__ == '__main__':
    main()

Solution (Python):
b = input()
if b == "A":
    print("T")
elif b == "C":
    print("G")
elif b == "G":
    print("C")
elif b == "T":
    print("A")

Solution (Python):
import sys
import math
from collections import Counter
import itertools



def II(): return int(sys.stdin.readline())
def MI(): return map(int, sys.stdin.readline().split())
def MI1(): return map(int1, sys.stdin.readline().split())

def LI(): return list(map(int, sys.stdin.readline().split()))

def LLI(rows_number): return [LI() for _ in range(rows_number)]
def SR(): return sys.stdin.readline().rstrip()

ascii_lowercase = 'abcdefghijklmnopqrstuvwxyz'
ascii_uppercase = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'
ascii_uppercase2 = 'ABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZ'


p2D = lambda x: print(*x, sep="\n")
p2E = lambda x: print(''.join(x))
p2S = lambda x: print(*x, sep=" ")



b=SR()
if b=='A':
    print('T')
elif b=='T':
    print('A')
elif b=='C':
    print('G')
else:
    print('C')

Solution (Python):
b = input()
if b == "A":
    print("T")
elif b == "C":
    print("G")
elif b == "G":
    print("C")
else:
    print("A")

Solution (Python):
b=input()
if b=="A":
    print("T")
elif b=="T":
    print("A")
elif b=="C":
    print("G")
elif b=="G":
    print("C")

Solution (Python):
b = input()

m = {
    'A': 'T',
    'T': 'A',
    'C': 'G',
    'G': 'C'
}

print(m[b])

Solution (Python):
b = input()

if b == 'A':
    print('T')
elif b == 'T':
    print('A')
elif b == 'C':
    print('G')
else:
    print('C')

Solution (Python):
dict = {'A':'T','C':'G','T':'A','G':'C'}
b = input()

print(dict[b])

Solution (Python):
b=input()
if b=="A":
  print("T")
if b=="T":
  print("A")
if b=="C":
  print("G")
if b=="G":
  print("C")

Solution (Python):
b = input()
enki = {
  'A': 'T'
  , 'T': 'A'
  , 'C': 'G'
  , 'G': 'C'
}
print(enki[b])

Solution (Python):
s = input()
if s == 'A':
  print('T')
elif s == 'T':
  print('A')
elif s == 'G':
  print('C')
else:
  print('G')

Solution (Python):


a = input()
print({"A" : "T", "T": "A", "C": "G", "G": "C"}[a])

Solution (Python):
i = input()
if i == "A":
    print("T")
elif i == "T":
    print("A")
elif i == "G":
    print("C")
else:
    print("G")

Solution (Python):
def resolve():
    b=input()
    if b=='A':
        print('T')
    elif b=='C':
        print('G')
    elif b==('T'):
        print('A')
    else:
        print('C')
resolve()

Solution (Python):
s = input()
if s == 'A':
  print('T')
elif s == 'T':
  print('A')
elif s == 'C':
  print('G')
else:
  print('C')

Solution (Python):
b = input()

if b == 'A':
  print('T')
elif b == 'C':
  print('G')
elif b == 'G':
  print('C')
else:
  print('A')

Solution (Python):
bases = [{'A', 'T'}, {'C', 'G'}]
b = input()
for i in bases:
    if b in i:
        print((i - set(b)).pop())

Solution (Python):
def main():
    b = input()
    for i in range(len(b)):
        if b[i] == "A":
            print("T",end="")
        elif b[i] == "T":
            print("A",end="")
        elif b[i] == "C":
            print("G",end="")
        elif b[i] == "G":
            print("C",end="")
    print()
if __name__ == "__main__":
    main()

Solution (Python):
b=str(input())
if b=='A':
  print('T')
elif b=='T':
  print('A')
elif b=='C':
  print('G')
else:
  print('C')

Solution (Python):
s = input()
if s == 'A':
  print('T')
elif s == 'T':
  print('A')
elif s == 'G':
  print('C')
else:
  print('G')

Solution (Python):
b = input()
if b == 'A':
  print('T')
if b == 'T':
  print('A')
if b == 'G':
  print('C')
if b == 'C':
  print('G')

Solution (Python):
b = input()

base = {'A': 'T', 'G': 'C', 'T': 'A', 'C': 'G'}

print(base[b])

Solution (Python):

b = str(input())
if b == 'A':
  print('T')
elif b == 'C':
  print('G')
elif b == 'G':
  print('C')
else:
  print('A')

Solution (Python):
b = input()

if b == 'A':
    print('T')
elif b == 'T':
    print('A')
elif b == 'G':
    print('C')
else:
    print('G')

Solution (Python):
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import accumulate, permutations, combinations, product, groupby
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left
from fractions import gcd
from heapq import heappush, heappop
from functools import reduce
def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def ZIP(n): return zip(*(MAP() for _ in range(n)))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

b = input()

if b == "A":
	print("T")
elif b == "T":
	print("A")
elif b == "C":
	print("G")
else:
	print("C")

Solution (Python):
a = "AT"
g = "GC"
b = input()

if a.count(b) :
    print(a.replace(b,""))
else:
  print(g.replace(b,""))

Solution (Python):
b = input()

at = "AT"
cg = "CG"

if at.count(b) == 1:
  print(at.replace(b, ""))
else:
  print(cg.replace(b, ""))

Solution (Python):
b = input()
print('T' if b=='A' else 'G' if b=='C' else 'C' if b=='G' else 'A')

Solution (Python):
dic={"A":"T","T":"A","G":"C","C":"G"}
print(dic[input()])

Solution (Python):
basePairs = {
    'A': 'T',
    'C': 'G',
    'G': 'C',
    'T': 'A',
}
b = input()
print(basePairs[b])

Solution (Python):
b=str(input())
strings="A","C","G","T"
if b=="A":
    print("T")
elif b=="C":
    print("G")
elif b=="G":
    print("C")
else:
    print("A")

Solution (Python):
b=input();print('A'if b=='T' else 'T' if b=='A' else 'G' if b=='C' else 'C')

Solution (Python):
b = input()
if b == 'A':
    print('T')

elif b == 'T':
    print('A')

elif b == 'C':
    print('G')

else:
    print('C')

Solution (Python):
b = str(input())

if b == 'A':
  print('T')
elif b == 'T':
  print('A')
elif b == 'C':
  print('G')
elif b == 'G':
  print('C')

Solution (Python):
b=input()
print('A' if b=='T' else 'T' if b=='A' else 'C' if b=='G' else 'G' )

Solution (Python):
b = input()
if b=="A": print("T")
elif b=="T": print("A")
elif b=="C": print("G")
else: print("C")

Solution (Python):
b = input().rstrip()
if b == 'A':
    print('T')
elif b == 'T':
    print('A')
elif b == 'G':
    print('C')
else:
    print('G')

Solution (Python):
b = input()
if b == "A":
    print("T")
elif b == "T":
    print("A")
elif b == "C":
    print("G")
else:
    print("C")

Solution (Python):
b = input()

base_pairs = {
    'A': 'T', 
    'C': 'G',
    'G': 'C',
    'T': 'A',
}

pair = base_pairs.get(b)

print(pair)

Solution (Python):
b = input()
if b == "A":
  print("T")
elif b == "T":
  print("A")
elif b == ("G"):
  print("C")
else:
  print("G")

Solution (Python):
b = input()
print("A" if b == "T" else "C" if b == "G" else "G" if b == "C" else "T")

Solution (Python):
s = input()
if s =='A':print('T')
elif s == 'T':print("A")
elif s == 'C':print("G")
elif s == 'G':print("C")

Solution (Python):

import sys

sr = lambda: sys.stdin.readline().rstrip()
ir = lambda: int(sr())
lr = lambda: list(map(int, sr().split()))

dic = {'A': 'T', 'T': 'A', 'C': 'G', 'G': 'C'}
B = sr()
answer = dic[B]
print(answer)

Solution (Python):
dic={'A':'T','C':'G','T':'A','G':'C'}
print(dic[input()])

Solution (Python):
b = input()
if b =="A":
    print("T")
elif b == "T":
    print("A")
elif b == "C":
    print("G")
else:
    print("C")

Solution (Python):
b = input()
if b == "A":
    print("T")
elif b == "T":
    print("A")
elif b == "C":
    print("G")
else:
    print("C")

Solution (Python):
s = input()
if s == "A":
    print("T")
elif s == "T":
    print("A")
elif s == "G":
    print("C")
else:
    print("G")

Solution (Python):

d = {"A":"T", "T":"A", "C":"G", "G":"C"}
print(d[input()])

Solution (Python):
b = input()
e = ["A", "T", "C", "G"]


if b == e[0]:
  print(e[1])
elif b == e[1]:
  print(e[0])
elif b == e[2]:
  print(e[3])
else:
  print(e[2])

Solution (Python):
at = "AT"
cg = "CG"
b = input()

if at.count(b) == 1:
  print(str(at.strip(b)))
else:
  print(str(cg.strip(b)))

Solution (Python):
b = input()
if b == 'A':
    b = 'T'
elif b == 'T':
    b = 'A'
elif b == 'C':
    b = 'G'
else:
    b = 'C'
print(b)