Jewel the Magician

Jewel is a promising magician. Recently, he has learned a technique to mesmerize his audience. Let’s…

Click here to read the complete problem statement.


If you need help solving this problem, mention your approach and ask specific questions. Please avoid sharing your code and asking the Community to figure out “what’s wrong”.

Need help to figer out my mistakes.

pos=list(map(int, input().split()))
counter=[0]*3

for _ in range(int(input())):
    for i in map(int, input().split()):
        i-=1
        pos[i]^=1
        counter[i]+=pos[i]

print(' '.join(map(str, counter)))