Problem:


Score : 100 points

Problem Statement

We have five variables x_1, x_2, x_3, x_4, and x_5.

The variable x_i was initially assigned a value of i.

Snuke chose one of these variables and assigned it 0.

You are given the values of the five variables after this assignment.

Find out which variable Snuke assigned 0.

Constraints

The values of x_1, x_2, x_3, x_4, and x_5 given as input are a possible outcome of the assignment by Snuke.

Input

Input is given from Standard Input in the following format:

x_1 x_2 x_3 x_4 x_5

Output

If the variable Snuke assigned 0 was x_i, print the integer i.

Sample Input 1

0 2 3 4 5

Sample Output 1

1

In this case, Snuke assigned 0 to x_1, so we should print 1.

Sample Input 2

1 2 0 4 5

Sample Output 2

3



Sample input:
0 2 3 4 5


Sample output:
1

Submission status: Accepted

Solution code:
def main():
    X = list(map(int, input().split()))
    for i, x in enumerate(X):
        if x == 0:
            print(i + 1)


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
X=input().split()

print(X.index("0")+1)

Submission status: Accepted

Solution code:
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())
a, b, c, d, e = M()
ans = 0
if a == 0:
    ans = 1
elif b == 0:
    ans = 2
elif c == 0:
    ans = 3
elif d == 0:
    ans = 4
else:
    ans = 5
print(ans)

Submission status: Accepted

Solution code:
X = list(map(int,input().split()))
print(15-sum(X))

Submission status: Accepted

Solution code:
a,b,c,d,e = map(int, input().split())
arr = [a,b,c,d,e]
for i in range(5):
    if arr[i] == 0:
        print(i+1)

Submission status: Accepted

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

for i in range(len(X)):
    if X[i] == 0:
        print(i+1)

Submission status: Accepted

Solution code:
s = list(map(int, input().split()))
print(s.index(0)+1)

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline
a = list(map(int,input().split()))
print(a.index(0)+1)

Submission status: Accepted

Solution code:
print([int(x) for x in input().split()].index(0) + 1)

Submission status: Accepted

Solution code:
x = list(map(int, input().split())) 
print("{}".format(x.index(0) + 1))

Submission status: Accepted

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

for i in range(5):
    if X[i]==0:
        print(i+1)

Submission status: Accepted

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

ans = x_list.index(0) + 1

print(ans)

Submission status: Accepted

Solution code:
a = list(map(int,input().split()))
for i in range(len(a)):
    if a[i] == 0:
        print(i+1)
        break

Submission status: Accepted

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

for i, x in enumerate(x_array):
    if x == 0:
        print(i + 1)
        exit()

Submission status: Accepted

Solution code:
l=list(map(int, input().split(' ')))
ans=0
for i in range(len(l)):
    if l[i]==0:
        print(ans+1)
        break
    else:
        ans+=1

Submission status: Accepted

Solution code:
A = list(map(int,input().split()))
print(15-sum(A))

Submission status: Accepted

Solution code:
x=list(map(int,input().split()))
print(x.index(0) + 1)

Submission status: Accepted

Solution code:
def main():
    a = list(map(int, input().split()))
    for i in range(len(a)):
        if a[i] == 0:
            print(i+1)
            return

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
def main():
    X = [int(a) for a in input().split()]

    for i in range(len(X)):
        if X[i] == 0:
            print(i + 1)
if __name__ == "__main__":
    main()

Submission status: Accepted

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

print(X.index(0)+1)

Submission status: Accepted

Solution code:
n,m,l,s,t=map(int,input().split())


if n==0:
    print(1)
elif m==0:
    print(2)
elif l==0:
    print(3)
elif s==0:
    print(4)
elif t==0:
    print(5)

Submission status: Accepted

Solution code:
a = list(map(int, input().split()))
for i in range(5):
  if a[i] == 0:
    print(i+1)

Submission status: Accepted

Solution code:
X = list(map(int, input().split()))
for i in range(len(X)):
    if X[i] == 0:
        print(i+1)
        break

Submission status: Accepted

Solution code:
def main():
    x = list(map(int, input().split()))
    return x.index(0) + 1
print(main())
#if main():
#    print('Yes')
#else:
#    print('No')

Submission status: Accepted

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

for i in range(5):
    if(a[i] != i+1):
        print(i+1)
        break

Submission status: Accepted

Solution code:
x1,x2,x3,x4,x5 = map(int,input().split())
if x1 == 0:
    print(1)
elif x2 == 0:
    print(2)
elif x3==0:
    print(3)
elif x4==0:
    print(4)
else:
    print(5)

Submission status: Accepted

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

for i in range(1, 6):
    if x[i-1] == 0:
        print(i)
        break

Submission status: Accepted

Solution code:
lis = list(map(int,input().split()))
nxt = 1
for i in lis:
    if i==0:
        print(nxt)
        break
    nxt+=1

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
 
## Library
 
import sys
from fractions import gcd
import math
from math import ceil,floor
import collections
from collections import Counter
import itertools
 
## input
 
# n=int(input())
# A,B,C,D=map(int, input().split())
# string = input()
# yoko = list(map(int, input().split()))
# tate = [int(input()) for _ in range(N)]
# N, M = map(int,input().split()) 
#    P = [list(map(int,input().split())) for i in range(M)]
 
X=list(map(int, input().split()))

for i in range(5):
    if X[i]==0:
        print(i+1)
        sys.exit()

Submission status: Accepted

Solution code:
x = list(map(int,input().split()))
for i in range(len(x)):
    if x[i] == 0:
        print(i+1)
        exit()

Submission status: Accepted

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

for i in range(5):
  if x[i]!=i+1:
    print(i+1)
    break

Submission status: Accepted

Solution code:
arr = list(map(int, input().split()))
for i in range(len(arr)):
    if arr[i] == 0:
        print(i+1)
        break

Submission status: Accepted

Solution code:
def main():
    x = list(map(int,input().split()))
    print(x.index(0)+1)

    
if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
# abc170_a.py
a = list(map(int,input().split()))
for i,v in enumerate(a):
    if v == 0:
        print(i+1)

Submission status: Accepted

Solution code:
N = input().split()
N = [int(s) for s in N]

print(N.index(0)+1)

Submission status: Accepted

Solution code:
xs = [int(x) for x in input().strip().split()]

for i in range(5):
    if xs[i] == 0:
        print(i+1)
        break

Submission status: Accepted

Solution code:
arr = list(map(str, input().strip().split()))
for i in range(0,5):
  if arr[i]=="0":
    print(i+1)

Submission status: Accepted

Solution code:
A = list(map(int, input().split()))
for i in range(len(A)):
  if(A[i]==0):
    print(i+1)
    break

Submission status: Accepted

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

for i in range(5):
    if x[i]==0:
        print(i+1)

Submission status: Accepted

Solution code:
a = list(map(int, input().split()))
for i, x in enumerate(a):
    if x == 0:
        print(i + 1)

Submission status: Accepted

Solution code:
#A
x = list(map(int,input().split()))
idx = x.index(0)
print(idx+1)

Submission status: Accepted

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

for i, x in enumerate(X):
  if x == 0:
    print(i+1)
    break

Submission status: Accepted

Solution code:
li = list(map(int, input().split()))
for i in range(5):
    if li[i] == 0:
        print(i+1)

Submission status: Accepted

Solution code:
## coding: UTF-8
A, B, C, D, E = map(int,input().split())

if(A == 0):
    print(1)
elif(B == 0):
    print(2)
elif(C == 0):
    print(3)
elif(D == 0):
    print(4)
else:
    print(5)

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline
def main():
    X = list(map(int, input().split()))
    for i in range(5):
        if X[i] == 0:
            print(i+1)

if __name__ == '__main__':
    main()

Submission status: Accepted

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

print(15-sum(xlist))

Submission status: Accepted

Solution code:
import sys
read = sys.stdin.read
readline = sys.stdin.readline
readlines = sys.stdin.readlines

def main():
    X = [int(i) for i in readline().split()]

    ans = X.index(0) + 1
    print(ans)
    


if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
def examA():
    X = LI()
    for i in range(len(X)):
        if X[i]==0:
            ans = i+1
    print(ans)
    return

def examB():
    ans = 0
    print(ans)
    return

def examC():
    ans = 0
    print(ans)
    return

def examD():
    ans = 0
    print(ans)
    return

def examE():
    ans = 0
    print(ans)
    return

def examF():
    ans = 0
    print(ans)
    return

from decimal import Decimal as dec
import sys,bisect,itertools,heapq,math,random
from copy import deepcopy
from heapq import heappop,heappush,heapify
from collections import Counter,defaultdict,deque
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
def I(): return int(input())
def LI(): return list(map(int,sys.stdin.readline().split()))
def DI(): return dec(input())
def LDI(): return list(map(dec,sys.stdin.readline().split()))
def LSI(): return list(map(str,sys.stdin.readline().split()))
def LS(): return sys.stdin.readline().split()
def SI(): return sys.stdin.readline().strip()
global mod,mod2,inf,alphabet,_ep
mod = 10**9 + 7
mod2 = 998244353
inf = 10**18
_ep = 10**(-12)
alphabet = [chr(ord('a') + i) for i in range(26)]

sys.setrecursionlimit(10**7)

if __name__ == '__main__':
    examA()

"""
142
12 9 1445 0 1
asd dfg hj o o
aidn
"""

Submission status: Accepted

Solution code:
a = [int(i) for i in input().split()]
for i in range(len(a)):
    if a[i] == 0:
        print(i+1)
        break

Submission status: Accepted

Solution code:
#デフォルト
import itertools
from collections import defaultdict
import collections
import math
import sys
sys.setrecursionlimit(200000)
mod = 1000000007

x = list(map(int,input().split()))

for i in range(5):
    if x[i] != i + 1:
        print(i+1)
        break

Submission status: Accepted

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

import sys
import numpy as np
int1 = lambda x: int(x) - 1
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
sys.setrecursionlimit(500000)

*x, = map(int, readline().split())

for i, x_ in enumerate(x, 1):
    if x_ == 0:
        print(i)

Submission status: Accepted

Solution code:
x_n =list(map(int,input().split()))
for i in range(5):
    if x_n[i]==0:
        print(i+1)

Submission status: Accepted

Solution code:
a,b,c,d,e =map(int,input().split())

if a==0:
    print(1)
elif b==0:
    print(2)
elif c==0:
    print(3)
elif d==0:
    print(4)
elif e==0:
    print(5)

Submission status: Accepted

Solution code:
a, b, c, d, e = map(int, input().split())
x = [a, b, c, d, e]

print(x.index(0) + 1)

Submission status: Accepted

Solution code:
def main():
    N = list(map(int, input().split()))
    for i in range(len(N)):
        if N[i] == 0:
            print(i + 1)
            exit()



if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
x = list(map(int, input().split()))
for i in range(5):
    if x[i] == 0:
        print(i + 1)
        exit()

Submission status: Accepted

Solution code:
import sys, re, os
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
# from fractions import gcd
from itertools import permutations, combinations, product, accumulate
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from functools import reduce
from bisect import bisect_left, insort_left
from heapq import heapify, heappush, heappop

INPUT = lambda: sys.stdin.readline().rstrip()
INT = lambda: int(INPUT())
MAP = lambda: map(int, INPUT().split())
S_MAP = lambda: map(str, INPUT().split())
LIST = lambda: list(map(int, INPUT().split()))
S_LIST = lambda: list(map(str, INPUT().split()))

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


def main():
    X = LIST()

    for i in range(5):
        if X[i] == 0: print(i+1)


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
def main():
    x = list(map(int, input().split()))
    print(x.index(0)+1)

main()

Submission status: Accepted

Solution code:
a = list(map(int,input().split()))
for i in range(5):
    if a[i]==0:
        print(i+1)
        break

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 = list(map(int, readline().split()))

    for i, x in enumerate(a, 1):
        if x == 0:
            print(i)


if __name__ == '__main__':
    main()

Submission status: Accepted

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

ans = 0

for i in x:
    ans += 1
    if i == 0:
        print(ans)
        break

Submission status: Accepted

Solution code:
N = [int(i) for i in input().split()]
print(N.index(0) + 1)

Submission status: Accepted

Solution code:
import sys, bisect, math, itertools, heapq, collections
from operator import itemgetter
# a.sort(key=itemgetter(i)) # i番目要素でsort
from functools import lru_cache
# @lru_cache(maxsize=None)
sys.setrecursionlimit(10**8)
input = sys.stdin.readline
INF = float('inf')
mod = 10**9 + 7
eps = 10**-7


def inp():
    '''
    一つの整数
    '''
    return int(input())


def inpl():
    '''
    一行に複数の整数
    '''
    return list(map(int, input().split()))


def str_inp():
    '''
    文字列をリストとして読み込む
    '''
    return list(input()[:-1])


x = inpl()
for i in range(5):
    if x[i] != i + 1:
        print(i + 1)
        break

Submission status: Accepted

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

for i, a in enumerate(x):
    if a == 0:
        print(i+1)
        break

Submission status: Accepted

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

ans = 0

for i in range(len(a)):
  if a[i] == 0:
  	ans = i + 1
  	break
  	
print(ans)

Submission status: Accepted

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

print(xs.index(0) + 1)

Submission status: Accepted

Solution code:
x = [int(i) for i in input().split()]

for i in range(len(x)):
    if (x[i] == 0):
        print(i+1)

Submission status: Accepted

Solution code:
import sys

x = list(map(int, input().split()))

for i in range(5):
	if x[i] == 0:
		print(i + 1)

Submission status: Accepted

Solution code:
x = list(map(int, input().split()))
for i in range(5):
    if x[i] == 0:
        print(i + 1)
        break

Submission status: Accepted

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

for i in range(5):
    if d[i] == 0:
        print(i+1)

Submission status: Accepted

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


def solve(x: "List[int]"):
    for i in range(len(x)):
        if x[i] == 0:
            print(i+1)
            return
    return


# Generated by 1.1.7.1 https://github.com/kyuridenamida/atcoder-tools  (tips: You use the default template now. You can remove this line by using your custom template)
def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    x = [int(next(tokens)) for _ in range(5)]  # type: "List[int]"
    solve(x)

if __name__ == '__main__':
    main()

Submission status: Accepted

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

for i in range(len(a)):
    if a[i] == 0:
        print(i+1)

Submission status: Accepted

Solution code:
import sys
def input(): return sys.stdin.readline().rstrip()

def main():
    x = list(map(int, input().split()))

    for i in range(5):
        if x[i] == 0:
            print(i + 1)

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
N = list(map(int, input().split()))
print(N.index(0)+1)

Submission status: Accepted

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

for i in range(len(x)):
    if x[i] == 0:
        print(i+1)
        exit()

Submission status: Accepted

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

print(*[i+1 for i,x in enumerate(x) if x==0])

Submission status: Accepted

Solution code:
# 2020/06/14
# AtCoder Beginner Contest 170 - A

# Input
a = list(map(int,input().split()))

# Calc
for i in range(5):
    if a[i] == 0:
        ans = i + 1

# Output
print(ans)

Submission status: Accepted

Solution code:
import sys
sys.setrecursionlimit(10**6)


def main(input, print):
    x = list(map(int, input().split()))
    for i in range(5):
        if x[i] == 0:
            print(i+1)


if __name__ == '__main__':
    main(sys.stdin.readline, print)

Submission status: Accepted

Solution code:
x = [int(a) for a in input().split()]
for i in range(len(x)):
    if x[i] == 0:
        print(i + 1)

Submission status: Accepted

Solution code:
A, B, C, D, E = map(int, input().split())

if A == 0:
    print(1)
elif B == 0:
    print(2)
elif C == 0:
    print(3)
elif D == 0:
    print(4)
elif E == 0:
    print(5)

Submission status: Accepted

Solution code:
from math import gcd

from math import factorial as f

from math import ceil,floor,sqrt
import math

import bisect
import re
import heapq


from copy import deepcopy
import itertools
from itertools import permutations

from sys import exit

ii = lambda : int(input())
mi = lambda : map(int,input().split())
li = lambda : list(map(int,input().split()))


yes = "Yes"
no = "No"


def main():
    x = li()
    for i in range(len(x)):
        if x[i] == 0:
            print(i+1)




main()

Submission status: Accepted

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


def solve(x: "List[int]"):
    return x.index(0) + 1

# Generated by 1.1.7.1 https://github.com/kyuridenamida/atcoder-tools
def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    x = [int(next(tokens)) for _ in range(5)]  # type: "List[int]"
    print(solve(x))

def test():
    import doctest
    doctest.testmod()

if __name__ == '__main__':
    #test()
    main()

Submission status: Accepted

Solution code:
x = input().split()
ans = x.index("0") + 1
print(ans)

Submission status: Accepted

Solution code:
import sys
import math
import heapq
sys.setrecursionlimit(10**7)
INTMAX = 9223372036854775807
INTMIN = -9223372036854775808
DVSR = 1000000007
def POW(x, y): return pow(x, y, DVSR)
def INV(x, m=DVSR): return pow(x, m - 2, m)
def DIV(x, y, m=DVSR): return (x * INV(y, m)) % m
def LI(): return [int(x) for x in sys.stdin.readline().split()]
def LF(): return [float(x) for x in sys.stdin.readline().split()]
def LS(): return sys.stdin.readline().split()
def II(): return int(sys.stdin.readline())
def FLIST(n):
    res = [1]
    for i in range(1, n+1): res.append(res[i-1]*i%DVSR)
    return res

L=LI()
print(L.index(0)+1)

Submission status: Accepted

Solution code:
x = list(map(int, input().split()))
for i,v in enumerate(x):
    if v == 0:
        print(i+1)
        exit()

Submission status: Accepted

Solution code:
dat = list(map(int, input().split()))
for i in range(1,6):
    if i not in dat:
        print(i)
        break

Submission status: Accepted

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

ans = 0
for i in range(5):
    if l[i] == 0:
        ans = i+1

print(ans)

Submission status: Accepted

Solution code:
import sys, math
#import io, os
#data = io.BytesIO(os.read(0,os.fstat(0).st_size)).readline
#from bisect import bisect_left as bl, bisect_right as br, insort
#from heapq import heapify, heappush, heappop
from collections import defaultdict as dd, deque, Counter
#from itertools import permutations,combinations
def data(): return sys.stdin.buffer.readline().strip()
def mdata(): return list(map(int, data().split()))
def outl(var) : sys.stdout.write(' '.join(map(str, var))+'\n')
def out(var) : sys.stdout.write(str(var)+'\n')
#sys.setrecursionlimit(100000)
INF = float('inf')
mod = 998244353
#from decimal import Decimal

l=mdata()
for i in range(5):
    if l[i]==0:
        out(i+1)
        exit()

Submission status: Accepted

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

ans = x.index(0) + 1

print(ans)

Submission status: Accepted

Solution code:
X = [int(v) for v in input().split()]
for i in range(len(X)):
    if X[i] == 0:
        print(i+1)

Submission status: Accepted

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

i = A.index(0)

print(i+1)

Submission status: Accepted

Solution code:
X = list(map(int, input().split()))
for i, x in enumerate(X):
    if x == 0:
        print(i + 1)

Submission status: Accepted

Solution code:
# template by 3xC and starkizard.
# contributors: 

#####################################################################################
from __future__ import division, print_function 

import sys
import os
from collections import Counter, deque, defaultdict
import itertools
import math
import io


"""Uncomment modules according to your need"""


# from bisect import bisect_left, bisect_right, insort
# from heapq import heappop, heapify, heappush
# from random import randint as rn
# from Queue import Queue as Q
# from copy import deepcopy
# from decimal import *
# import re
# import operator

#####################################################################################
# this enables you to write python3 code with PyPy2 (Python 2)
if sys.version_info[0] < 3:
    input = raw_input
    range = xrange

    filter = itertools.ifilter
    map = itertools.imap
    zip = itertools.izip

#####################################################################################

"""value of mod"""
MOD = 998244353
mod = 10**9 + 7

"""Uncomment next 4 lines if doing huge recursion"""
# import threading
# threading.stack_size(1<<27)
# sys.setrecursionlimit(10000

def prepare_factorial(mod=mod):
    """ returns two lists, factorial and inverse factorial modulo argument by default 10**9 +7 """
    # Comment code out when you don't need inverse factorial or vice versa
    fact = [1]
    for i in range(1, 200005):
        fact.append((fact[-1] * i) % mod)

    ifact = [0] * 200005
    ifact[200004] = pow(fact[200004], mod - 2, mod)
    for i in range(200004, 0, -1):
        ifact[i - 1] = (i * ifact[i]) % mod

    return fact, ifact

def modinv(n, p):
    """ returns N inverse modulo p """
    return pow(n, p - 2, p)

def ncr(n, r,  fact, ifact):
    """ takes 4 arguments: n , r and factorial and inverse factorial lists"""
    t = (fact[n] * (ifact[r]*ifact[n-r]) % MOD)% MOD
    return t


def get_n(Sum):    
    """this function returns the maximum n for which Summation(n) <= Sum"""
    ans = (-1 + sqrt(1 + 8*Sum))//2
    return ans

def sieve(n):
    """ returns a list of prime numbers till n """
    if n < 2: return list()
    prime = [True for _ in range(n + 1)]
    p = 3
    while p * p <= n:
        if prime[p]:
            for i in range(p * 2, n + 1, p):
                prime[i] = False
        p += 2
    r = [2]
    for p in range(3, n + 1, 2):
        if prime[p]:
            r.append(p)
    return r



def divs(n, start=1):
    """ returns a list of all divisors till n """
    divisors = []
    for i in range(start, int(math.sqrt(n) + 1)):
        if n % i == 0:
            if n / i == i:
                divisors.append(i)
            else:
                divisors.extend([i, n // i])
    return divisors



def divn(n, primes):
    """ returns the number of divisors, two arguments n and the sieve till n """
    divs_number = 1
    for i in primes:
        if n == 1:
            return divs_number
        t = 1
        while n % i == 0:
            t += 1
            n //= i
        divs_number *= t



def lrfind(d, x, default=-1):
    """ Takes 2 arguments an iterable and an element. returns a tuple (firstoccurence,lastoccurence) -1 if not found """
    left = right = -1
    for i in range(len(d)):
        if d[i] == x:
            if left == -1: left = i
            right = i
    if left == -1:
        return default, default
    else:
        return left, right

def gcd(x, y): # math.gcd is slower
    """ returns greatest common divisor of x and y """
    while y:
        x, y = y, x % y
    return x

def check_sorted(a):
    ''' returns True/False '''
    for i in range(len(a)-1):
        if a[i]>a[i+1]:
            return False
    return True
def ceil(n, k=1): return n // k + (n % k != 0) #returns math.ceil but protecting against floating inconsistencies
def input(): return sys.stdin.readline().strip()
def ii(): return int(input()) #inputs integer
def mi(): return map(int, input().split()) # inputting space seperated variables for example x,y,z
def li(): return list(map(int, input().split())) #inputting a space seperated list of integers
def lw(): return input().split() #inputting a space seperated list of strings
def lcm(a, b): return abs(a * b) // gcd(a, b) #returns LCM of two arguments
def prr(a, sep=' ', end='\n'): print(sep.join(map(str, a)), end=end) #For printing an iterable with seperator sep as optional second argument (default : " "), ending character (default: "\n") as optional third
def dd(): return defaultdict(int) #returns a dictionary with values defaulted to 0
def ddl(): return defaultdict(list) #returns a dictionary with values defaulted to []
def write(s): return sys.stdout.write(s)












###################################################################
def main():
    #CODE GOES HERE:
    a=li()
    for i in range(len(a)):
        if(a[i]==0):
            print(i+1)
            return












































""" -------- Python 2 and 3 footer by Pajenegod and c1729 ---------"""

py2 = round(0.5)
if py2:
    from future_builtins import ascii, filter, hex, map, oct, zip
    range = xrange

import os, sys
from io import IOBase, BytesIO

BUFSIZE = 8192

class FastIO(BytesIO):
    newlines = 0

    def __init__(self, file):
        self._file = file
        self._fd = file.fileno()
        self.writable = "x" in file.mode or "w" in file.mode
        self.write = super(FastIO, self).write if self.writable else None

    def _fill(self):
        s = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
        self.seek((self.tell(), self.seek(0, 2), super(FastIO, self).write(s))[0])
        return s

    def read(self):
        while self._fill(): pass
        return super(FastIO, self).read()

    def readline(self):
        while self.newlines == 0:
            s = self._fill();
            self.newlines = s.count(b"\n") + (not s)
        self.newlines -= 1
        return super(FastIO, self).readline()

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


class IOWrapper(IOBase):

    def __init__(self, file):
        self.buffer = FastIO(file)
        self.flush = self.buffer.flush
        self.writable = self.buffer.writable
        if py2:
            self.write = self.buffer.write
            self.read = self.buffer.read
            self.readline = self.buffer.readline
        else:
            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')
# sys.stdin = open('input.txt', 'r')
# sys.stdout = open('output.txt', 'w')

""" main function"""

if __name__ == '__main__':
    main()
    # threading.Thread(target=main).start()

Submission status: Accepted

Solution code:
import sys, io, os, re
import bisect
from pprint import pprint
from math import sin, cos, pi, radians, sqrt, floor
from copy import copy, deepcopy
from collections import deque
from fractions import gcd
from functools import reduce
from itertools import groupby

n1 = lambda: int(sys.stdin.readline().strip())
nn = lambda: list(map(int, sys.stdin.readline().strip().split()))
f1 = lambda: float(sys.stdin.readline().strip())
fn = lambda: list(map(float, sys.stdin.readline().strip().split()))
s1 = lambda: sys.stdin.readline().strip()
sn = lambda: list(sys.stdin.readline().strip().split())
nl = lambda n: [n1() for _ in range(n)]
fl = lambda n: [f1() for _ in range(n)]
sl = lambda n: [s1() for _ in range(n)]
nm = lambda n: [nn() for _ in range(n)]
fm = lambda n: [fn() for _ in range(n)]
sm = lambda n: [sn() for _ in range(n)]

def array1(n): return [0] * n
def array2(n, m): return [[0] * m for x in range(n)]
def array3(n, m, l): return [[[0] * l for y in xrange(m)] for x in xrange(n)]

X = nn()

for i in range(len(X)):
    if (X[i] == 0):
        print(i+1)

Submission status: Accepted

Solution code:

x = list(map(int, input().split()))

i = x.index(0)

print(i+1)

Submission status: Accepted

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

print(x_list.index(0) + 1)

Submission status: Accepted

Solution code:
import math
import string
import collections
from collections import Counter
from collections import deque
from decimal import Decimal
import sys
import fractions
from operator import itemgetter


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


def nCr(n, r):
    return math.factorial(n)//(math.factorial(n-r)*math.factorial(r))


def has_duplicates2(seq):
    seen = []
    for item in seq:
        if not(item in seen):
            seen.append(item)
    return len(seq) != len(seen)


def divisor(n):
    divisor = []
    for i in range(1, n+1):
        if n % i == 0:
            divisor.append(i)
    return divisor


# coordinates
dx = [-1, -1, -1, 0, 0, 1, 1, 1]
dy = [-1, 0, 1, -1, 1, -1, 0, 1]
x = readints()
# print(x)
for i in range(5):
    if x[i] == 0:
        print(i+1)

Submission status: Accepted

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

for i in range(5):
  if A[i] == 0:
    print(i + 1)

Submission status: Accepted

Solution code:
def main():
    import sys
    L=list(map(int,sys.stdin.readline().split()))
    for i,x in enumerate(L):
        if x==0:
            print(i+1)
            return


main()

Submission status: Accepted

Solution code:
x=[int(i) for i in input().split()]
for i in range(5):
    if x[i]==0:
        print(i+1)

Submission status: Accepted

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

cnt = 1
for var in a:
    if (int(var)==0):
        print(cnt)
    else:
        cnt = cnt + 1

Submission status: Accepted

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

ans = 15 - sum(x)
print(ans)

Submission status: Accepted

Solution code:
a=list(map(int,input().split()))
for i in range(5):
  if a[i]==0:
    print(i+1)
    break

Submission status: Accepted

Solution code:
ls = list(map(int,input().split()))
print(ls.index(0)+1)

Submission status: Accepted

Solution code:
l = list(map(int, input().split()))
for i in range(5):
    if l[i] == 0:
        print(i+1)

Submission status: Accepted

Solution code:
X = list(map(int, input().split()))
ans = 0
for i in range(5):
    if X[i] == 0:
        ans = i+1
print(ans)