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



Sample input:
3
1


Sample output:
2

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

Solution code:
import collections
import math
import operator as op
from functools import reduce
import numpy as np
import math
import bisect


def main():
    A = int(input())
    B = int(input())
    if A > B:
        A, B = B, A
    # A <= B
    if A == 1 and B == 2:
        print(3)
    elif A == 1 and B == 3:
        print(2)
    elif A == 2 and B == 2:
        print(1)


if __name__ == '__main__':
    main()

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

an = [A, B]

for i in range(1,4):
    if (i + 1) in an:
        pass
    else:
        print(i+1)
        break

Submission status: Wrong Answer

Solution code:
test = ""
test = \
"""
1
2
"""
test = list(reversed(test.strip().splitlines()))
if test:
    def input2():
        return test.pop()
else:
    def input2():
        return input()
    
    
a = int(input2())
b = int(input2())
print(6-a-b)

Submission status: Wrong Answer

Solution code:
ab = list(map(int, input().split()))

print(min(set([1, 2, 3]) - set(ab)))

Submission status: Wrong Answer

Solution code:
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)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

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

batsu = [a, b]
batsu.sort()

if batsu == [1, 2]:
    print(3)
elif batsu == [1, 3]:
    print(2)
else:
    print(3)

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

Solution code:
def main():
    ab = list(map(int, input().split()))
    if not 1 in ab:
        return 1
    if not 2 in ab:
        return 2
    else:
        return 3


print(main())

Submission status: Wrong Answer

Solution code:
a=(int(x) for x in input().split())
b=(int(x) for x in input().split())
numbers=[a,b]
for i in range(1,4):
  if i not in numbers:
    print(i)

Submission status: Accepted

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

cands = list(range(1,4))
cands.remove(A)
cands.remove(B)
print(cands[0])

Submission status: Accepted

Solution code:
a=int(input())
b=int(input())
print('1' if a+b==5 else'2' if a+b==4 else '3' )

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

print(6-a-b)

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
A=int(input())
B=int(input())
list1=[]
list1.append(A)
list1.append(B)
if 1 not in list1:
  print(1)
elif 2 not in list1:
  print(2)
elif 3 not in list1:
  print(3)

Submission status: Accepted

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

c = 1+2+3

print(c - (a+b))

Submission status: Accepted

Solution code:
a= int(input())

b = int(input())

print(6 - a - b)

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
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)
elif (a == 1 and b == 3) or (a == 3 and b == 1) :
  print(2)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
X = {1,2,3}
a = {int(input())}
b = {int(input())}
print(list(X-a-b)[0])

Submission status: Accepted

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

Submission status: Accepted

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

print(6 - A - B)

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
import sys
from itertools import chain


def solve(A: int, B: int):
    answer = 6 - A - B
    return answer


def main():
    tokens = chain(*(line.split() for line in sys.stdin))
    A = int(next(tokens))  # type: int
    B = int(next(tokens))  # type: int
    answer = solve(A, B)
    print(answer)


if __name__ == "__main__":
    main()

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
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 == 2:
    print(1)
  else:
    print(2)

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
num_l = [1, 2, 3]
num_l.remove(int(input()))
num_l.remove(int(input()))
print(num_l.pop())

Submission status: Accepted

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

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

Submission status: Accepted

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

print(6-A-B)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
A = input()
B = input()
candidate = set(('1', '2', '3'))
exclude = set((A, B))
print((candidate - exclude).pop())

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import os
import heapq
import sys,threading
import math
import bisect
import operator
from collections import defaultdict
sys.setrecursionlimit(10**5)
from io import BytesIO, IOBase
def gcd(a,b):
    if b==0:

        return a
    else:
        return gcd(b,a%b)
def power(x, p,m):
    res = 1
    while p:
        if p & 1:
            res = (res * x) % m
        x = (x * x) % m
        p >>= 1
    return res
def inar():
    return [int(k) for k in input().split()]

def lcm(num1,num2):
    return (num1*num2)//gcd(num1,num2)

def main():
    take=[0]*3
    take[int(input())-1]=1
    take[int(input())-1]=1
    for i in range(3):
        if take[i]==0:
            print(i+1)




BUFSIZE = 8192


class FastIO(IOBase):
    newlines = 0

    def __init__(self, file):
        self._fd = file.fileno()
        self.buffer = BytesIO()
        self.writable = "x" in file.mode or "r" not in file.mode
        self.write = self.buffer.write if self.writable else None

    def read(self):
        while True:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            if not b:
                break
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines = 0
        return self.buffer.read()

    def readline(self):
        while self.newlines == 0:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            self.newlines = b.count(b"\n") + (not b)
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines -= 1
        return self.buffer.readline()

    def flush(self):
        if self.writable:
            os.write(self._fd, self.buffer.getvalue())
            self.buffer.truncate(0), self.buffer.seek(0)


class IOWrapper(IOBase):
    def __init__(self, file):
        self.buffer = FastIO(file)
        self.flush = self.buffer.flush
        self.writable = self.buffer.writable
        self.write = lambda s: self.buffer.write(s.encode("ascii"))
        self.read = lambda: self.buffer.read().decode("ascii")
        self.readline = lambda: self.buffer.readline().decode("ascii")


sys.stdin, sys.stdout = IOWrapper(sys.stdin), IOWrapper(sys.stdout)
input = lambda: sys.stdin.readline().rstrip("\r\n")

if __name__ == "__main__":
    main()
    #threadin.Thread(target=main).start()

Submission status: Accepted

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

ans = {1,2,3} - {a,b}
print(ans.pop())

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
from collections import defaultdict, Counter
from itertools import product, groupby, count, permutations, combinations
from math import pi, sqrt
from collections import deque
from bisect import bisect, bisect_left, bisect_right
from string import ascii_lowercase
from functools import lru_cache
import sys
sys.setrecursionlimit(10000)
INF = float("inf")
YES, Yes, yes, NO, No, no = "YES", "Yes", "yes", "NO", "No", "no"
dy4, dx4 = [0, 1, 0, -1], [1, 0, -1, 0]
dy8, dx8 = [0, -1, 0, 1, 1, -1, -1, 1], [1, 0, -1, 0, 1, 1, -1, -1]


def inside(y, x, H, W):
    return 0 <= y < H and 0 <= x < W


def ceil(a, b):
    return (a + b - 1) // b


def sum_of_arithmetic_progression(s, d, n):
    return n * (2 * s + (n - 1) * d) // 2


def gcd(a, b):
    if b == 0:
        return a
    return gcd(b, a % b)


def lcm(a, b):
    g = gcd(a, b)
    return a / g * b


def solve():
    A = int(input())
    B = int(input())
    for i in range(1, 4):
        if i != A and i != B:
            print(i)
            break


def main():
    solve()


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
a = int(input())
b = int(input())
if a + b == 3:
    print(3)
elif a + b == 4:
    print(2)
else:
    print(1)

Submission status: Accepted

Solution code:
A = int(input())
B = int(input())
lis = [1, 2, 3]
x = lis.index(A)
y = lis.index(B)
lis[x] = 0
lis[y] = 0
ans = sum(lis)
print(ans)

Submission status: Accepted

Solution code:
e=input
print(int(e())^int(e()))

Submission status: Accepted

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

Submission status: Accepted

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

print(6 - a - b)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a=int(input())
b = int(input())
s = set([1,2,3])
s.remove(a)
s.remove(b)
print(*s)

Submission status: Accepted

Solution code:
A = int(input())
B = int(input())
 
# 頭いい方法！
print(6-A-B)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

print(ans[0])

Submission status: Accepted

Solution code:
A = int(input())
B = int(input())
for i in range(1, 4):
  if i not in [A, B]:
    print(i)

Submission status: Accepted

Solution code:

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

Submission status: Accepted

Solution code:
a=int(input())
b=int(input())
num=[1,2,3]
num.remove(a)
num.remove(b)
print(*num)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = [1,2,3]

s.remove(int(input()))
s.remove(int(input()))

print(s[0])

Submission status: Accepted

Solution code:
import sys

readline = sys.stdin.readline
MOD = 10 ** 9 + 7
INF = float('INF')
sys.setrecursionlimit(10 ** 5)


def main():
    A = int(readline())
    B = int(readline())

    print(6 - A - B)


if __name__ == '__main__':
    main()

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
A = input()
B = input()
ans = '123'
print(ans.replace(A, '').replace(B, ''))

Submission status: Accepted

Solution code:
A = int(input())

B = int(input())

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

Submission status: Accepted

Solution code:
A = int(input())
B = int(input())
anss = set([1, 2, 3])
anss.remove(A)
anss.remove(B)
for i in anss:
    print(i)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S=input()
S+=input()
print(*[a for a in '123' if a not in S])

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
A = input()
B = 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")

Submission status: Accepted

Solution code:
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)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
ans = [1,2,3]
for i in [0,1]:
    y = int(input())
    ans.remove(y)
print(ans[0])

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
def main():
    A = int(input())
    B = int(input())

    ans = 6 - A - B

    print(ans)


if __name__ == "__main__":
    main()

Submission status: Accepted

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

Submission status: Accepted

Solution code:
choice = [1,2,3]

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

for c in choice:
    if c != A and c != B:
        print(c)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
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)
elif (A==3 and B==1) or (A==1 and B==3):
    print(2)

Submission status: Accepted

Solution code:
a = []
for i in range(2):
    a.append(int(input()))
if 1 not in a:
    print(1)
elif 2 not in a:
    print(2)
else:
    print(3)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())
b = int(input())
if a == 1 or b == 1:
    if a == 2 or b == 2:
        print(3)
    else:
        print(2)
else:
    print(1)

Submission status: Accepted

Solution code:
a = int(input())
b  =int(input())
set_ = set([1,2,3])
set_.remove(a)
set_.remove(b)
print(set_.pop())

Submission status: Accepted

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

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)
elif a==3 and b==2:print(1)

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
# Generated by https://github.com/kyuridenamida/atcoder-tools
from typing import *
import collections
import functools
import itertools
import math
import sys

INF = float('inf')


def solve(A: int, B: int):
    return [a for a in [1, 2, 3] if A != a != B][0]


def main():

    sys.setrecursionlimit(10 ** 6)

    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    A = int(next(tokens))  # type: int
    B = int(next(tokens))  # type: int
    print(f'{solve(A, B)}')


if __name__ == '__main__':
    main()

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a, b = int(input()), int(input())
if 1 not in [a, b]:
	print(1)
elif 2 not in [a, b]:
	print(2)
else:
	print(3)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s={int(input()) for s in range(2)}
a={1,2,3}
print(list(a-s)[0])

Submission status: Accepted

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

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

print(l[0])

Submission status: Accepted

Solution code:
a=int(input())
b=int(input())
li=[a,b]
li.sort()
if li==[1,2]:print(3)
elif li==[2,3]:print(1)
else:print(2)

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
l = []
l.append(int(input().rstrip()))
l.append(int(input().rstrip()))
print(6 - sum(l))

Submission status: Accepted

Solution code:
n1=int(input())
n2=int(input())

s=[n1,n2]
s1=[1,2,3]
d=list(set(s1)-set(s))
print(d.pop())

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a=int(input())
b=int(input())
ab={a,b}
s={1,2,3}
ss=s-ab
print(list(ss)[0])

Submission status: Accepted

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

n = [1,2,3]
n[a-1] = 0
n[b-1] = 0

for i in range(len(n)):
  if n[i] != 0:
    print(n[i])

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
from sys import stdin
import sys
import math
from functools import reduce
import functools
import itertools
from collections import deque,Counter,defaultdict
from operator import mul
import copy
# ! /usr/bin/env python
# -*- coding: utf-8 -*-
import heapq
sys.setrecursionlimit(10**6)
# INF =  float("inf")
INF = 10**18
import bisect
import statistics
mod = 10**9+7
# mod = 998244353

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

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

Submission status: Accepted

Solution code:
# ABC148
# A Round One
a = int(input())
b = int(input())
L = [1,2,3]
L.remove(a)
L.remove(b)
print(L[0])

Submission status: Accepted

Solution code:
def main():
    a = int(input())
    b = int(input())
    for i in (1, 2, 3):
        if i != a and i != b:
            print(i)

main()

Submission status: Accepted

Solution code:
import sys, bisect, math, itertools, string, queue, copy
# import numpy as np
# import scipy
# from collections import Counter,defaultdict,deque
# from itertools import permutations, combinations
# from heapq import heappop, heappush
# # input = sys.stdin.readline
# sys.setrecursionlimit(10**8)
# mod = 10**9+7
def inp(): return int(input())
def inpm(): return map(int,input().split())
def inpl(): return list(map(int, input().split()))
def inpls(): return list(input().split())
def inplm(n): return list(int(input()) for _ in range(n))
def inplL(n): return [list(input()) for _ in range(n)]
def inplT(n): return [tuple(input()) for _ in range(n)]
def inpll(n): return [list(map(int, input().split())) for _ in range(n)]
def inplls(n): return sorted([list(map(int, input().split())) for _ in range(n)])

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

Submission status: Accepted

Solution code:
import sys, bisect, math, itertools, string, queue, copy
import numpy as np
import scipy
from collections import Counter,defaultdict,deque
from itertools import permutations, combinations
from heapq import heappop, heappush
# input = sys.stdin.readline
sys.setrecursionlimit(10**8)
mod = 10**9+7
def inp(): return int(input())
def inpm(): return map(int,input().split())
def inpl(): return list(map(int, input().split()))
def inpls(): return list(input().split())
def inplm(n): return list(int(input()) for _ in range(n))
def inplL(n): return [list(input()) for _ in range(n)]
def inplT(n): return [tuple(input()) for _ in range(n)]
def inpll(n): return [list(map(int, input().split())) for _ in range(n)]
def inplls(n): return sorted([list(map(int, input().split())) for _ in range(n)])

a = inp()
b = inp()

ans = 0
if a != 1 and b != 1:
    ans = 1
elif a != 2 and b != 2:
    ans = 2
else:
    ans = 3

print(ans)

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline
ins = lambda: input().rstrip()
ini = lambda: int(input().rstrip())
inm = lambda: map(int, input().split())
inl = lambda: list(map(int, input().split()))

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

Submission status: Accepted

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

print(({1,2,3} - {A, B}).pop())

Submission status: Accepted

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

print(list({1,2,3} - {A, B})[0])

Submission status: Accepted

Solution code:
import bisect,collections,copy,heapq,itertools,math,numpy,string
import sys
sys.setrecursionlimit(10**7)

def S(): return sys.stdin.readline().rstrip()
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())

def main():
    A = I()
    B = I()
    print(6-(A+B))

main()

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
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)

Submission status: Accepted

Solution code:
x = [int(input()) for i in range(2)]
if 1 not in x:
    print(1)
elif 2 not in x:
    print(2)
else:
    print(3)

Submission status: Accepted

Solution code:
a=int(input())
b=int(input())
c=[1,2,3]
c.pop(c.index(a))
c.pop(c.index(b))
print(c[0])

Submission status: Accepted

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

print(*({"1", "2", "3"} - {A, B}))

Submission status: Accepted

Solution code:
x,y=map(int,open(0).read().split())
for i in range(1,4):
  if x==i or y==i:
    continue
  print(i)

Submission status: Accepted

Solution code:
l = [1, 2, 3]

a = int(input())
l.remove(a)

b = int(input())
l.remove(b)

print(l[0])

Submission status: Accepted

Solution code:
a = [input() for i in range(2)]
b = [int(s) for s in a]
print(6 - sum(b))

Submission status: Accepted

Solution code:

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


if __name__ == "__main__":
    main()

Submission status: Accepted

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

Submission status: Accepted

Solution code:
A=int(input())
B=int(input())
if 1 not in [A,B]:
    print(1)
if 2 not in [A,B]:
    print(2)
if 3 not in [A,B]:
    print(3)

Submission status: Accepted

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

Submission status: Accepted

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

print(6-(A+B))

Submission status: Accepted

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

Submission status: Accepted

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

s1 = {1, 2, 3}
s2 = set()
s2.add(A)
s2.add(B)
for i in s1 - s2:
    print(i)

Submission status: Accepted

Solution code:
#https://atcoder.jp/contests/abc148/tasks/abc148_a
A = int(input())
B = int(input())
print(6-A-B)

Submission status: Accepted

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

li = [a,b]

if 1 not in li:
    print("1")
elif 2 not in li:
    print("2")
else:
    print("3")

Submission status: Accepted

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

for a in range(1,4):
    if a != A and a != B:
        print(a)

Submission status: Accepted

Solution code:
not_ans = []
not_ans.append(int(input()))
not_ans.append(int(input()))
for i in range(1, 4):
    if i not in not_ans:
        print(i)

Submission status: Accepted

Solution code:
n = int(input())
m = int(input())
if n!=1 and m!=1:
    print(1)
elif n!=2 and m!=2:
    print(2)
else:
    print(3)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a=int(input())
b=int(input())
ans=6
for i in range(1,4):
    if a==i or b==i:
            ans-=i
print(ans)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
#!/usr/bin/env python3

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

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

for i in range(1, 4):
    if i not in (A, B):
        print(i)

Submission status: Accepted

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

C=sorted([A,B])
ans=0
 
if C==[1,2]:
  ans=3
elif C==[1,3]:
  ans=2
else:
  ans=1
  
print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

ls = [1,2,3]
for num in ls:
  if num == A or num == B:
    continue
  print(num)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())
b = int(input())
 
t = set([1, 2, 3])
s = set([a,b])
ans = t - s
print(list(ans)[0])

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline

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

print(6-a-b)

Submission status: Accepted

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

ans = set()
ans.add(a)
ans.add(b)
all = {1,2,3}
print((all-ans).pop())

Submission status: Accepted

Solution code:
ab = set([input() for _ in range(2)])
s = {'1', '2', '3'}
print(''.join(s-ab))

Submission status: Accepted

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

Submission status: Accepted

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

print(*(set([1,2,3])-set([A,B])))

Submission status: Accepted

Solution code:
a=int(input())
b=int(input())
z=1^2^3
print (z^a^b)

Submission status: Accepted

Solution code:
a_list=[1,2,3]

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

a_list.remove(a)
a_list.remove(b)

print(a_list[0])

Submission status: Accepted

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