random list args just not includes in mydict and disappear and i dont know what to do. my code -
def openOrSenior(data):
data = dict(data)
print(data)
output = []
for k, v in data.items():
if k >= 55 and v > 7:
output += ['Senior']
else:
output += ['Open']
return output
print(openOrSenior( [[17, 18], [57, 25], [56, 24], [41, 2], [22, 27], [48, 15], [39, 21], [41, 2]] ))
output-
{17: 18, 57: 25, 56: 24, 41: 2, 22: 27, 48: 15, 39: 21}
['Open', 'Senior', 'Senior', 'Open', 'Open', 'Open', 'Open']
where is [41, 2]? it happens sometimes with diferent numbers and places in list, so i can't understand where is the problem. I need it for this kata in codewars https://www.codewars.com/kata/5502c9e7b3216ec63c0001aa/train/python