def row_minimum(x,L):
L=L
if x==\'1\':
row_minimum1=min(L[0],L[1],L[2],L[3],L[4])
return row_minimum1
elif x==\'2\':
row_minimum2=min(L[5],L[6],L[7],L
You may want something like this:
def user_input(y):
if y in ['1','2','3','A','B','C','D','E']:
condition = False
else:
condition = True
while condition == True:
z=input("Enter a row (as a number) or a column (as and uppercase letter):")
if z in ['1','2','3','A','B','C','D','E']:
condition = False
return z
print user_input('1')
print user_input('4')
Edit
If you get something like
, its because you are printing the function. (And it's not an error)
print user_input # This is not wath you want
This instead is what you want:
print user_input(...) # Where ... is the parameter you are giving to your function