Module Module1

    Sub Main()

        Dim A As Integer = CInt(Console.ReadLine())
        Dim B As Integer = CInt(Console.ReadLine())

        Dim c As Integer = 6 - A - B

        Console.WriteLine(c)
        'Console.ReadLine()

    End Sub

End Module

