Problem:
 Score: 100 points    Problem Statement  Takahashi is solving quizzes. He has easily solved all but the last one.  The last quiz has three choices: 1 , 2 , and 3 .  With his supernatural power, Takahashi has found out that the choices A and B are both wrong.  Print the correct choice for this problem.      Constraints   Each of the numbers A and B is 1 , 2 , or 3 .  A and B are different.         Input  Input is given from Standard Input in the following format:  A  B       Output  Print the correct choice.        Sample Input 1 3
1      Sample Output 1 2  When we know 3 and 1 are both wrong, the correct choice is 2 .       Sample Input 2 1
2      Sample Output 2 3

Solution (Python):
a = 6 - int(input())
a = a - int(input())
print(a)

Solution (Python):
print(6-input()-input())

Solution (Python):
import sys
input = sys.stdin.readline

def main():
    ans = [1, 2, 3]
    for i in range(2):
        a = int(input())
        ans.remove(a)
    print(ans[0])


if __name__ == "__main__":
    main()

Solution (Python):
a= int(input())
b= int(input())

print(6-a-b)

Solution (Python):
A = int(input())
B = int(input())
print(6-A-B)

Solution (Python):
a=int(input())
b=int(input())
li=[1,2,3]
li.remove(a)
li.remove(b)
print(li[0])

Solution (Python):
A=int(input())
B=int(input())

S={1,2,3}

S.remove(A)
S.remove(B)

print(list(S)[0])

Solution (Python):
A=int(input())
B=int(input())
L=[1,2,3]
L.remove(A)
L.remove(B)
print(L[0])

Solution (Python):
import sys
import math


print(6-int(input())-int(input()))

Solution (Python):
a=int(input())
b=int(input())
print(6-a-b)

Solution (Python):
a = int(input())
b = int(input())
l = [a,b]
for i in range(1,4):
    if i in l:pass
    else:
        print(i)

Solution (Python):
A = int(input())
B = int(input())
l = [1, 2, 3]
l.remove(A)
l.remove(B)
print(l[0])

Solution (Python):
A = int(input())
B = int(input())
print(6-A-B)

Solution (Python):
a=int(input())
b=int(input())
print(6-a-b)

Solution (Python):








a = int(input())
b = int(input())
 
ans = 6-a-b

print(ans)

Solution (Python):
A = int(input())
B = int(input())

sentaku = [1,2,3]
for i in range(3):
    if sentaku[i]!=A and sentaku[i]!=B:
        print(sentaku[i])

Solution (Python):
a = int(input())
b = int(input())
print(6 -(a + b ))

Solution (Python):
a = int(input())
b = int(input())
ma = max(a , b)
mi = min(a , b)
if ma == 3 :
    print(ma - mi)
else :
    print(ma + mi)

Solution (Python):
s = int(input())
t = int(input())
a =[1,2,3]
a.remove(s)
a.remove(t)
print(a[0])

Solution (Python):
a = int(input())
b = int(input())

ans = 6 - (a + b)
print(ans)

Solution (Python):
mc = [1, 2, 3]
for i in range(2):
    mc.remove(int(input()))
print(*mc)

Solution (Python):
ans = [1,2,3]
ans.remove(int(input()))
ans.remove(int(input()))
print(ans[0])

Solution (Python):
a = int(input())
b = int(input())

print(6 - a - b)

Solution (Python):
a = int(input())
b = int(input())
print(6-a-b)

Solution (Python):
a = int(input())
b = int(input())
print(6-a-b)

Solution (Python):
a = int(input())
b = int(input())

ab = set((a, b))
ans = set((1, 2, 3))-ab
print(*ans)

Solution (Python):
a = int(input())
b = int(input())

ab = {a, b}
ans = {1, 2, 3}-ab
print(*ans)

Solution (Python):
input1 = [int(input()) for i in range(2)]
numbers = [m for m in range(1,4)] 
for n in input1:
    numbers.remove(n)
print(numbers[0])

Solution (Python):
A = int(input())
B = int(input())
if A + B == 3:
    print(3)
elif A + B == 4:
    print(2)
else:
    print(1)

Solution (Python):
print(6-int(input())-int(input()))

Solution (Python):
a = int(input())
b = int(input())

if (a == 1 and b == 2) or (a == 2 and b == 1):
	print(3)
elif (a == 2 and b == 3) or (a == 3 and b == 2):
	print(1)
else:
	print(2)

Solution (Python):
a=int(input())
b=int(input())
c=int(6-a-b)
print(c)

Solution (Python):


import logging


def main():
    import sys
    input = sys.stdin.readline
    sys.setrecursionlimit(10 ** 6)

    def dump(*args):
        sys.stderr.write(str(args))
    

    a = int(input())
    b = int(input())
    print(*set([1, 2, 3]).difference(set([a]), set([b])))
    


if __name__ == '__main__':
    main()

Solution (Python):


import logging


def main():
    import sys
    input = sys.stdin.readline
    sys.setrecursionlimit(10 ** 6)

    def dump(*args):
        sys.stderr.write(str(args))
    

    a = int(input())
    b = int(input())
    print(*set([1, 2, 3]).difference(set([a]), set([b])))
    dump('Error occurred!', 1, 136513, [2521.26262, 624652])


if __name__ == '__main__':
    main()

Solution (Python):



def main():
    import sys
    input = sys.stdin.readline
    sys.setrecursionlimit(10**6)
    

    a = int(input())
    b = int(input())
    print(*set([1, 2, 3]).difference(set([a]), set([b])))
    sys.stderr.write('Error occurred!')


if __name__ == '__main__':
    main()

Solution (Python):



def main():
    import sys
    input = sys.stdin.readline
    sys.setrecursionlimit(10**6)
    

    a = int(input())
    b = int(input())
    print(*set([1, 2, 3]).difference(set([a]), set([b])))
    


if __name__ == '__main__':
    main()

Solution (Python):



from fractions import gcd 
from functools import reduce
import sys
sys.setrecursionlimit(200000000)
from inspect import currentframe




def printargs2err(*args):
    names = {id(v):k for k,v in currentframe().f_back.f_locals.items()}
    print(', '.join(names.get(id(arg),'???')+' : '+repr(arg) for arg in args),file=sys.stderr)






def printglobals():
    for (symbol, value) in globals().items():
        print('symbol="%s"、value=%s' % (symbol, value),file=sys.stderr)
def printlocals():
    for (symbol, value) in locals().items():
        print('symbol="%s"、value=%s' % (symbol, value),file=sys.stderr)

        

def resolve():
    A=[0,1,2,3]
    A[int(input())]=0
    A[int(input())]=0
    print(sorted(A)[-1])
    

"""


"""
"""
お前カッコ閉じるの忘れてるだろ
"""

import sys
from io import StringIO
import unittest

class TestClass(unittest.TestCase):
    def assertIO(self, input, output):
        stdout, stdin = sys.stdout, sys.stdin
        sys.stdout, sys.stdin = StringIO(), StringIO(input)
        resolve()
        sys.stdout.seek(0)
        out = sys.stdout.read()[:-1]
        sys.stdout, sys.stdin = stdout, stdin
        self.assertEqual(out, output)
    def test_入力例_1(self):
        input = """3
1"""
        output = """2"""
        self.assertIO(input, output)
    def test_入力例_2(self):
        input = """1
2"""
        output = """3"""
        self.assertIO(input, output)

if __name__=="__main__":resolve()

Solution (Python):
lst = ["1","2","3"]
for i in range(2):
  lst.remove(input())
print(lst[0])

Solution (Python):
a = int(input())
b = int(input())
print(6-a-b)

Solution (Python):
A = int(input())
B = int(input())

q = [True, True, True]
q[A - 1] = False
q[B - 1] = False

print(q.index(True) + 1)

Solution (Python):
a = int(input())
b = int(input())
  
if a + b ==  3:
  print(3)
elif a + b == 4:
  print(2)
elif a+b == 5:
  print(1)

Solution (Python):
a = int(input())
b = int(input())
n = 6 - a - b
print(n)

Solution (Python):

import sys


def solve(A: int, B: int):
    ans = [1, 2, 3]
    ans.remove(A)
    ans.remove(B)
    print(ans[0])
    



def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    A = int(next(tokens))  
    B = int(next(tokens))  
    solve(A, B)

if __name__ == '__main__':
    main()

Solution (Python):
A=int(input())
B=int(input())
if A+B ==3:
    print(3)
elif A+B==4:
    print(2)
else:
    print(1)

Solution (Python):
A=[1,2,3]
A.remove(int(input()))
A.remove(int(input()))
print(A[0])

Solution (Python):
a = int(input())
b = int(input())

if a != 3 and b != 3:
    print(3)
elif a != 2 and b != 2:
    print(2)
else:
    print(1)

Solution (Python):



from math import *
from copy import *
from string import *				
from random import *				
from sys import stdin
from sys import maxsize
from operator import *				
from itertools import *
from collections import Counter		
from collections import defaultdict 

'''

'''

def solve(l):
	n = len(l)
	

A = int(stdin.readline())
B = int(stdin.readline())
print(6-A-B)

Solution (Python):
a = int(input())
b = int(input())

for i in range(1,4):
    if i != a and i!=b:
        print(i)

Solution (Python):
A=int(input())
B=int(input())
print (6-A-B)

Solution (Python):
import sys
input = sys.stdin.readline
MOD = 10**9 + 7
INF = float('INF')

def main():
    a = int(input())
    b = int(input())

    print(6-a-b)

if __name__ == '__main__':
    main()

Solution (Python):
print(6-int(input())-int(input()))

Solution (Python):
a=int(input())
b=int(input())
print(6-a-b)

Solution (Python):
A = int(input())
B = int(input())
C = A+B
print(6-C)

Solution (Python):
print(6-sum(map(int,open(0))))

Solution (Python):
a = int(input())
b = int(input())

c = [1,2,3]
c.remove(a)
c.remove(b)

print(c[0])

Solution (Python):
A=int(input())
B=int(input())
ans=[1,2,3]
ans.remove(A)
ans.remove(B)
print(ans.pop())

Solution (Python):
A=int(input())
B=int(input())
li=[1,2,3]
li.remove(A)
li.remove(B)
print(li[0])

Solution (Python):
A = int(input())
B = int(input())
list = [1,2,3]
list.remove(A)
list.remove(B)
print(list[0])

Solution (Python):
a = input()
b = input()
print([e for e in  ['1','2','3'] if e !=a and e != b].pop())

Solution (Python):
a = int(input())
b = int(input())
print(6 - a - b)

Solution (Python):
a = int(input())
b = int(input())

cand = [1,2,3]
cand.remove(a)
cand.remove(b)
print(cand[0])

Solution (Python):
a = int(input())
b = int(input())

print(6-a-b)

Solution (Python):
a = int(input())
b = int(input())

l = [a, b]

for i in range(1, 4):
    if i not in l: 
        print(i)
        break

Solution (Python):
ans = [1, 2, 3]
ans.remove(int(input()))
ans.remove(int(input()))
print(ans[0])

Solution (Python):
A = int(input())
B = int(input())

print(6 - A - B)

Solution (Python):
a = int(input())
b = int(input())
print(6 - a - b)

Solution (Python):
A = input()
B = input()
C = int(A) + int(B)
if C == 3:
    print(3)
elif C == 4:
    print(2)
else:
    print(1)

Solution (Python):
a = int(input())
b = int(input())
print(6-(a+b))

Solution (Python):
a = int(input())
b = int(input())
if a+b == 3:
  print(3)
elif a+b == 4:
  print(2)
else:
  print(1)

Solution (Python):
import sys


def solve():
    readline = sys.stdin.buffer.readline
    mod = 10 ** 9 + 7
    a = int(readline())
    b = int(readline())
    print(1 ^ 2 ^ 3 ^ a ^ b)


if __name__ == '__main__':
    solve()

Solution (Python):
a = int(input())
b = int(input())
if a+b == 3:
  print(3)
elif a+b == 4:
  print(2)
else:
  print(1)

Solution (Python):
A, B = [int(input()) for _ in range(2)]
print(6 - A - B)

Solution (Python):
a=int(input())
b=int(input())

print(*(set(range(1,4))-{a,b}))

Solution (Python):
a = int(input())
b = int(input())
if a == 1:
    if b == 2:
        print(3)
    else:
        print(2)
elif a == 2:
    if b == 1:
        print(3)
    else:
        print(1)
else:
    if b == 1:
        print(2)
    else:
        print(1)

Solution (Python):
a = int(input())
b= int(input())
print(6-a-b)

Solution (Python):
A=int(input())
B=int(input())
for x in range(1,4):
    if A!=x and B!=x:
        print(x)

Solution (Python):
A=int(input())
B=int(input())
if A!=1 and B!=1:
    print("1")
if A!=2 and B!=2:
    print("2")
if A!=3 and B!=3:
    print("3")

Solution (Python):
a,b=[int(input()) for _ in range(2)]
for i in range(1,4):
    if i!=a and i!=b:
        print(i)
        break

Solution (Python):
a=input()
b=input()
print(6-int(a)-int(b))

Solution (Python):
a=int(input())
b=int(input())
print(6-a-b)

Solution (Python):
a=int(input())
b=int(input())

print(6-a-b)

Solution (Python):
a=int(input())
b=int(input())
print(6-a-b)

Solution (Python):
num_0 = int(input())
num_1 = int(input())

ara = [1,2,3]
ara.remove(num_0)
ara.remove(num_1)

print(ara[0])

Solution (Python):
A=int(input())
B=int(input())
print(6-A-B)

Solution (Python):
a = int(input())
b = int(input())
ans = {1,2,3} - {a,b}
print(*ans)

Solution (Python):
a = int(input())
b = int(input())

print(6 - a - b)

Solution (Python):
print(6-int(input())-int(input()))

Solution (Python):
ans=[1,2,3]
ans.remove(int(input()))
ans.remove(int(input()))
print(*ans)

Solution (Python):
A = int(input())
B = int(input())
print(6 - A - B)

Solution (Python):
A=int(input())
B=int(input())
for i in range(1,4):
  if i!=A and i!=B:
    print(i)

Solution (Python):
A = int(input())
B = int(input())

if A == 1 and B == 2:
  print(3)
elif A == 2 and B == 1:
  print(3)
elif A == 3 and B == 1:
  print(2)
elif A == 1 and B == 3:
  print(2)  
elif A == 2 and B == 3:
  print(1)
elif A == 3 and B == 2:
  print(1)

Solution (Python):
import sys
import socket

hostname = socket.gethostname()

if hostname == 'F451C':
    sys.stdin = open('a1.in')


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


def read_str_list():
    return input().split()


def read_int():
    return int(input())


def read_str():
    return input()


def main():
    A = read_int()
    B = read_int()
    print(6 - A - B)


main()

Solution (Python):
a=int(input())
b=int(input())
print(6-a-b)

Solution (Python):
a= int(input())
b= int(input())
c= 6
print(c-(a+b))

Solution (Python):
A = int(input())
B = int(input())

if A+B < 4:
    print(3)
elif A+B > 4:
    print(1)
else :
    print(2)

Solution (Python):
print(6-int(input())-int(input()))

Solution (Python):
if __name__ == '__main__':
  candidate=["1","2","3"]
  a=input()
  b=input()
  candidate.remove(a)
  candidate.remove(b)
  print(candidate[0])

Solution (Python):


a = int(input())
b = int(input())
print(6 - a - b)

Solution (Python):
A=int(input())
B=int(input())  
C=6-A-B
print(C)

Solution (Python):
a = int(input())
b = int(input())
lis = [a, b]
ans = 2
if max(lis) == 2:
    ans = 3
elif min(lis) == 2:
    ans = 1
print(ans)

Solution (Python):
a=int(input())
b=int(input())
print(6-a-b)

Solution (Python):
a = int(input())
b = int(input())
l = [1,2,3]
l.remove(a)
l.remove(b)
print(l[0])

Solution (Python):
a = int(input())
b = int(input())
lst = [1, 2, 3]

lst.remove(a)
lst.remove(b)

print(*lst)

Solution (Python):
A = int(input())
B = int(input())

list = [1,2,3]

list.remove(A)
list.remove(B)

print(list[0])

Solution (Python):
a=int(input())
b=int(input())
print([i for i in range(1, 4) if i not in [a, b]][0])

Solution (Python):
A=int(input())
B=int(input())
C=[1,2,3]
C.remove(A)
C.remove(B)
print(C[0])

Solution (Python):
A = int(input())
B = int(input())
ans = [1, 2, 3]
for i in range(3):
    if A == i:
        ans.remove(i)
    if B == i:
        ans.remove(i)

print(ans[0])

Solution (Python):
a=int(input())
b=int(input())
for i in range(1,4):
    if i!=a and i!=b:
        print(i)

Solution (Python):
a = int(input())
b = int(input())
q =[1,2,3]
q.remove(a)
q.remove(b)
print(q[0])

Solution (Python):
A=int(input())
B=int(input())
list=[1,2,3]
list.remove(A)
list.remove(B)
print(list[0])

Solution (Python):
A=int(input())
B=int(input())
if A==1 and B==2:
  print(3)
elif A==2 and B==3:
  print(1)
elif A==3 and B==1:
  print(2)
elif A==1 and B==3:
  print(2)
elif A==2 and B==1:
  print(3)
elif A==3 and B==2:
  print(1)

Solution (Python):
a = [int(input()) for i in range(2)]
A = a[0]
B = a[1]

ans = 6 - (A + B)
print(ans)

Solution (Python):
A = input()
B = input()

ans = ["1", "2", "3"]
ans.remove(A)
ans.remove(B)
print(ans[0])

Solution (Python):
a, b = map(int, [input() for _ in range(2)])

print(6 - a - b)

Solution (Python):
print(int(6/int(input())/int(input())))

Solution (Python):
A = int(input())
B = int(input())

L = [1, 2, 3]
L.remove(A)
L.remove(B)

print(L[0])

Solution (Python):
A=int(input())
B=int(input())
ans = 6-A-B
print(ans)

Solution (Python):
ans=[1,2,3]
a=int(input())
b=int(input())
ans.remove(a)
ans.remove(b)
print(ans[0])

Solution (Python):
a = int(input())
b = int(input())
if a > b:a,b = b,a
if a == 1 and b == 2:print(3)
if a == 2 and b == 3:print(1)
if a == 1 and b == 3:print(2)

Solution (Python):
sol=[1,2,3]
ch_1=int(input())
ch_2=int(input())
sol.remove(ch_1)
sol.remove(ch_2)
print(sol[0])

Solution (Python):
L = [1,2,3]
for i in range(2):
    L.remove(int(input()))
print(L[0])

Solution (Python):
a=int(input())
b=int(input())
list={a,b}
for i in range(1,4):
  if i in list:
    continue
  else:
    print(i)

Solution (Python):
A=int(input())
B=int(input())
print(A^B)

Solution (Python):
A=int(input())
B=int(input())
print(6-A-B)

Solution (Python):
u={1,2,3}
AB=[int(input()) for i in range(2)]
print(list(u-set(AB))[0])

Solution (Python):
A = int(input())
B = int(input())
l = [1, 2, 3]
for i in l:
    if i not in [A, B]:
        print(i)

Solution (Python):
A = int(input())
B = int(input())

print(6-A-B)

Solution (Python):
ab = [int(input()) for i in range(2)]

ans_list = [1, 2, 3]
result = list(set(ans_list) - set(ab))
print(result[0])

Solution (Python):
A = int(input())
B = int(input())
print(6 - A - B)

Solution (Python):
A, B = map(int, open(0).read().split())

if A+B == 3:
    print(3)
elif A+B == 4:
    print(2)
else:
    print(1)

Solution (Python):
A = int(input())
B = int(input())
answer = [1, 2, 3]
answer.remove(A)
answer.remove(B)
print(answer[0])

Solution (Python):
a=set([input() for _ in range(2)])
ans={'1','2','3'}
b=list(ans-a)
print(b[0])

Solution (Python):
A=int(input())
B=int(input())
print(6-A-B)

Solution (Python):



a = input()
b = input()
print(list({'1', '2', '3'} - {a, b})[0])

Solution (Python):
def solve():
    N = int(input())
    M = int(input())

    l = [N, M]
    a = 0
    if not 1 in l:
        a = 1
    elif not 2 in l:
        a = 2
    else:
        a = 3
    
    return a

print(solve())

Solution (Python):
a = int(input())
b = int(input())
print(6-a-b)

Solution (Python):
A = int(input())
B = int(input())

print(6-A-B)

Solution (Python):
a = int(input())
b = int(input())

for i in range(1, 4):
  if i != a and i != b:
    print(i)
    break

Solution (Python):
a = int(input())
b = int(input())
print(6-(a+b))

Solution (Python):
a=int(input())
b=int(input())
print(6-a-b)

Solution (Python):
c = [1, 2, 3]
c.remove(int(input()))
c.remove(int(input()))
print(c[0])

Solution (Python):
a = int(input())
b = int(input())
if a and b in range(1,4) and a is not b:
    print([x for x in [1,2,3] if x not in [a,b]][0])

Solution (Python):
A = int(input())
B = int(input())
list=[1,2,3]
list.remove(A)
list.remove(B)
print(list[0])

Solution (Python):
import sys
read=sys.stdin.buffer.read
A,B=map(int,read().split())
l=[1,2,3]
res = filter(lambda x:x!=A and x!=B, l)
print(next(res))

Solution (Python):
S1=int(input())
S2=int(input())
print(6-S1-S2)

Solution (Python):
import sys
stdin = sys.stdin

ns = lambda: stdin.readline().rstrip()
ni = lambda: int(ns())
na = lambda: list(map(int, stdin.readline().split()))

a = ni()
b = ni()
for i in range(1, 4):
    if i != a and i != b:
        print(i)

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

print(6 - int(a) - int(b))

Solution (Python):
A = int(input())
B = int(input())

N = [1,2,3]

N.remove(A)
N.remove(B)

print(N[0])

Solution (Python):
A = int(input())
B = int(input())
li = [1, 2, 3]
li.remove(A) 
li.remove(B)
print(li[0])

Solution (Python):
A=int(input())
B=int(input())
x=[1,2,3]
del x[x.index(A)]
del x[x.index(B)]
print(x[0])

Solution (Python):
l = [1,2,3]
a = int(input())
b = int(input())
c = [o for o in l if o not in [a,b]]
print(c[0])

Solution (Python):

listA=[1,2,3]

listR=[int(input()) for i in range(2)]

for i in listR:
    listA.remove(i)

print(listA[0])

Solution (Python):
a=int(input())
b=int(input())
lis=[1,2,3]
lis.remove(a)
lis.remove(b)
print(lis[0])

Solution (Python):
list = [1, 2, 3]

A = int(input())
B = int(input())
list.remove(A)
list.remove(B)

print(list[0])

Solution (Python):
a = int(input())
b = int(input())
remain = 6 - (a + b)
print(remain)

Solution (Python):
a = int(input())
b = int(input())
for i in range(1,4):
    if i != a and i != b:
        print(i)

Solution (Python):
print(6-int(input())-int(input()))

Solution (Python):

import sys


def solve(A: int, B: int):
    print(6//A//B)
    return



def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    A = int(next(tokens))  
    B = int(next(tokens))  
    solve(A, B)

if __name__ == '__main__':
    main()

Solution (Python):
a = int(input())
b = int(input())

print(6-a-b)

Solution (Python):
A = int(input())
B = int(input())

print(6-(A+B))

Solution (Python):
a = [1, 2, 3]
x, y = int(input()), int(input())
a.remove(x)
a.remove(y)
print(a[0])

Solution (Python):
A=int(input())
B=int(input())
l=[1,2,3]
l.remove(A)
l.remove(B)
print(l[0])

Solution (Python):
print("123".replace(input(), "").replace(input(), ""))

Solution (Python):
print(6-int(input())-int(input()))

Solution (Python):
a = int(input())
b = int(input())
print(6-a-b)

Solution (Python):
def main():
    a = input()
    b = input()
    l = ['1','2','3']
    l.remove(a)
    l.remove(b)
    print(l[0])
main()

Solution (Python):
def main():
	a=input()
	b=input()
	l=['1','2','3']
	l.remove(a)
	l.remove(b)
	print(l[0])
main()

Solution (Python):
def judge(a, b):
  if a == 1:
    if b == 2:
      return 3
    else:
      return 2
  elif a == 2:
    if b == 1:
      return 3
    else:
      return 1
  else:
    if b == 1:
      return 2
    else:
      return 1

a = int(input())
b = int(input())

x = judge(a, b)

print(x)

Solution (Python):
a = int(input())
b = int(input())
print(6//a//b)

Solution (Python):
a=int(input())
b=int(input())
print(6-a-b)

Solution (Python):
a = int(input())
b = int(input())

x = [1,2,3]

for i in x:
    if( i == a):continue
    if( i == b):continue
    print(i)

Solution (Python):
a=int(input())
b=int(input())
abc=[1,2,3]
abc.remove(a)
abc.remove(b)
print(abc[0])

Solution (Python):
print(6-int(input())-int(input()))

Solution (Python):
x = int(input())
y = int(input())
if x==1 and y==2:
    print(3)
elif x==1 and y==3:
    print(2)
elif x==2 and y==3:
    print(1)
elif x==2 and y==1:
    print(3)
elif x==3 and y==1:
    print(2)
elif x==3 and y==2:
    print(1)

Solution (Python):
A=int(input())
B=int(input())
num=[1,2,3]
num.remove(A)
num.remove(B)
last=num[0]
print(int(last))

Solution (Python):
A=int(input())
B=int(input())
if 1 != A and 1 != B:
  print(1)
elif 2 != A and 2 != B:
  print(2)
else:
  print(3)

Solution (Python):

a = int(input())
b = int(input())

if a + b == 3:
  print(3)
elif a + b == 4:
  print(2)
else:
  print(1)

Solution (Python):

A = int(input())
B = int(input())
tmp = [1, 2, 3]
tmp.remove(A)
tmp.remove(B)
print(tmp[0])

Solution (Python):
import sys
sys.setrecursionlimit(12345678)
import itertools
from collections import Counter
from collections import defaultdict
from collections import deque
import bisect
from heapq import heappush, heappop


def main():
    ans = [1,2,3]
    a = int(input())
    b = int(input())
    ans.remove(a)
    ans.remove(b)
    print(ans.pop())

if __name__ == '__main__':
    main()

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





c = int(a)
d = int(b)
e = 6-c-d
print(e)

Solution (Python):
print(int(6 - int(input()) - int(input())))

Solution (Python):
print(6 - int(input()) - int(input()))

Solution (Python):
a = int(input())
b = int(input())
print(6 - a - b)

Solution (Python):
A = input()
B = input()

print(6-int(A)-int(B))

Solution (Python):
A = int(input())
B = int(input())
print(6 - (A+B))

Solution (Python):
A = input()
B = input()
arr = ['1', '2', '3']
arr.remove(A)
arr.remove(B)
print(arr[0])

Solution (Python):
import math
from functools import reduce
from collections import deque
import sys
sys.setrecursionlimit(10**7)


def get_nums_l():
    return [ int(s) for s in input().split(" ")]


def get_nums_n(n):
    return [ int(input()) for _ in range(n)]

def log(*args):
    print("DEBUG:", *args, file=sys.stderr)

a = int(input())
b = int(input())

for i in range(1,4):
    if i not in (a,b):
        print(i)

Solution (Python):
A = int(input())
B = int(input())
a = A*B
print(6//a)

Solution (Python):

A = int(input())
B = int(input())
tmp = [1, 2, 3]
tmp.remove(A)
tmp.remove(B)
print(tmp[0])

Solution (Python):
a = int(input())
b = int(input())

arr = [0] * 4
arr[a] = 1
arr[b] = 1
for i in range(1,4):
    if arr[i] == 0:
        print(i)

Solution (Python):
A=int(input())
B=int(input())  
C=6-A-B
print(C)

Solution (Python):
A=int(input())
B=int(input())
print(6-(A+B))

Solution (Python):
A = int(input())
B = int(input())
print(6-A-B)

Solution (Python):
A = int(input())
B = int(input())
print (6-A-B)

Solution (Python):



def main():
    a = int(input())
    b = int(input())
    print(6 - (a + b))



if __name__ == '__main__':
    main()

Solution (Python):
a = int(input())
b = int(input())
for i in range(1,4):
    if i != a and i !=b:
        print(i)

Solution (Python):
a = int(input())
b = int(input())

l = [1,2,3]
l.remove(a)
l.remove(b)

print(*l)

Solution (Python):
def main():
    x=[1,2,3]
    a=int(input())
    b=int(input())
    x.pop(x.index(a))
    x.pop(x.index(b))
    print(x.pop())

main()

Solution (Python):
print(6 - int(input()) - int(input()))

Solution (Python):
A=int(input())
B=int(input())
answer=[1, 2, 3]
answer.remove(A)
answer.remove(B)
print(answer[0])

Solution (Python):
a = int(input())
b = int(input())
x = [1,2,3]
x.remove(a)
x.remove(b)
print(x[0])

Solution (Python):
a=int(input())
b=int(input())

ans=[1,2,3]
ans.remove(a)
ans.remove(b)
print(ans[0])

Solution (Python):
a = int(input())
b = int(input())

ans = [1, 2, 3]
ans.remove(a)
ans.remove(b)

print(ans[0])

Solution (Python):
a=int(input())
b=int(input())
print(6-a-b)

Solution (Python):
f = int(input())
s = int(input())

lst = [1, 2, 3]
lst.remove(f)
lst.remove(s)

print(lst[0])

Solution (Python):
a=int(input())
b=int(input())
print(6-a-b)

Solution (Python):
A = int(input())
B = int(input())

if A == 1:
    if B == 2:
        ans = 3
    if B == 3:
        ans = 2
elif A == 2:
    if B == 1:
        ans = 3
    if B == 3:
        ans = 1
elif A == 3:
    if B == 1:
        ans = 2
    if B == 2:
        ans = 1

print(ans)

Solution (Python):
import sys
ans=[1,2,3]
ans.remove(int(sys.stdin.readline()))
ans.remove(int(sys.stdin.readline()))
print(*ans)

Solution (Python):
A = int(input())
B = int(input())
print(6-A-B)

Solution (Python):
a = int(input())
b = int(input())
c = 6 - a - b
print(c)

Solution (Python):
a = 0
for i in range(2):
  a += int(input())
if a == 3:
  print(3)
elif a == 5:
  print(1)
else:
  print(2)

Solution (Python):
n=int(input())
l=int(input())

print(6-n-l)

Solution (Python):
A = int(input())
B = int(input())
print(int((6/A)/B))

Solution (Python):
A = int(input())
B = int(input())

ans = set([1, 2, 3])
ans.remove(A)
ans.remove(B)
a = 0
print(list(ans)[0])

Solution (Python):
a = int(input())
b = int(input())
print(6-(a+b))

Solution (Python):




def main():
    A = int(input())
    B = int(input())
    result = [1, 2, 3]
    result.remove(A)
    result.remove(B)
    print(result[0])


if __name__ == "__main__":
    main()

Solution (Python):
A,B=input(),input()
for i in ('1','2','3'):
    if i not in (A,B):
        print(i)

Solution (Python):
if __name__ == '__main__':

	arr = [1,2,3]
	chk = [int(input()) for _ in range(2)]
	print(*(set(arr) ^ set(chk)))

Solution (Python):
A = int(input())
B = int(input())
print(6-A-B)

Solution (Python):
s = [input() for i in range(2)]
a = int(s[0])
b = int(s[1])

print(6-a-b)

Solution (Python):
A = int(input())
B = int(input())
print(6-A-B)

Solution (Python):
A = int(input())
B = int(input())

print(6-(A+B))

Solution (Python):
a = int(input())
b = int(input())

if (a != 3) and (b != 3):
    print("3")
elif (a != 2) and (b != 2):
    print("2")
else:
    print("1")

Solution (Python):
A = int(input())
B = int(input())
print(6 - A - B)

Solution (Python):
A = int(input())
B = int(input())
print(6 - (A + B))

Solution (Python):
a=int(input())
b=int(input())
print(6-(a+b))

Solution (Python):
n= int(input())
m = int(input())
print(6-(n+m))

Solution (Python):
se = set([1,2,3])
AB = set([int(input()) for _ in range(2)])
ans = se-AB
print(*ans)

Solution (Python):
a = int(input())
b = int(input())
print(6-a-b)

Solution (Python):
A = int(input())
B = int(input())
print(6 - A - B)

Solution (Python):
a = int(input())
b = int(input())
if a+b == 3:
    print(3)
elif a+b == 4:
    print(2)
elif a+b == 5:
    print(1)

Solution (Python):
A = input()
B = input()

Cor = 6-(int(A)+int(B))
print(Cor)

Solution (Python):
a = 0
a += int(input())
a += int(input())

print(6 - a)

Solution (Python):
a = int(input())
b = int(input())
print(6-a-b)

Solution (Python):
a=int(input())
b=int(input())
print(6-a-b)

Solution (Python):
def main():
    A = int(input())
    B = int(input())
    if A > B:
        A, B = B, A

    if A == 1 and B == 2:
        print(3)
    elif A == 1 and B == 3:
        print(2)
    else:
        print(1)

if __name__ == '__main__':
    main()

Solution (Python):
a,b=int(input()),int(input())
print(6-a-b)

Solution (Python):
a = int(input())
b = int(input())
print(6-a-b)

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
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()))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

A = INT()
B = INT()

if (A + B) == 3:
	print(3)
if (A + B) == 4:
	print(2)
if (A + B) == 5:
	print(1)

Solution (Python):
a = int(input())
b = int(input())
print(6-a-b)

Solution (Python):
A=int(input())
B=int(input())
print(6-A-B)

Solution (Python):
a=input()
b=input()
l=["1","2","3"]
l.remove(a)
l.remove(b)
print(l[0])

Solution (Python):
a = int(input())
b = int(input())

answer_list = [1,2,3]

answer_list.remove(a)
answer_list.remove(b)

print(answer_list[0])

Solution (Python):
print(6 - sum([int(input()) for i in range(2)]))

Solution (Python):
A = int(input())
B = int(input())
print(A ^ B)

Solution (Python):
A = int(input())
B = int(input())

tmp = [1, 2, 3]
tmp.remove(A)
tmp.remove(B)

print(tmp[0])

Solution (Python):
a = int(input())
b = int(input())
print(6-a-b)

Solution (Python):
a = int(input())
b = int(input())
print(6 - a - b)

Solution (Python):
a = int(input())
b = int(input())
print(6-a-b)

Solution (Python):
a=int(input())
b=int(input())
print(6-a-b)

Solution (Python):
l = []
l.append(input())
l.append(input())
if '1' not in l:
  print('1')
elif '2' not in l:
  print('2')
elif '3' not in l:
  print('3')

Solution (Python):
print(6 - int(input()) - int(input()))

Solution (Python):
A = int(input())
B = int(input())
print(list({1,2,3}-{A,B})[0])

Solution (Python):
A = int(input())
B = int(input())
C = [1,2,3]
C.remove(A)
C.remove(B)
print(C[0])

Solution (Python):
A=input()
B=input()

A=int(A)
B=int(B)

if A==1 and B==2:
	print(3)

elif A==1 and B==3:
	print(2)
    
elif A==2 and B==1:
	print(3)
    
elif A==2 and B==3:
	print(1)
    
elif A==3 and B==1:
	print(2)
    
else:
	print(1)

Solution (Python):
a = int(input())
b = int(input())
print(6-a-b)

Solution (Python):
a = int(input())
b = int(input())

print(6 - a - b)

Solution (Python):
A = int(input())
B = int(input())
n_list = [1, 2, 3]
n_list.remove(A)
n_list.remove(B)
for num in n_list:
  print(num)

Solution (Python):
A = int(input())
B = int(input())

List = [1, 2, 3]

List.remove(A)
List.remove(B)

print(List[0])