a = 'joao 1 0 10 2 3'
b = a.split()
c = []
for i in b:
try:
c.append(int(i))
except ValueError:
pass
print(max(c))
print(min(c))
#https://pt.stackoverflow.com/q/346896/101
YSA9ICdqb2FvIDEgMCAxMCAyIDMnCmIgPSBhLnNwbGl0KCkKYyA9IFtdCmZvciBpIGluIGI6CiAgICB0cnk6CiAgICAgICAgYy5hcHBlbmQoaW50KGkpKQogICAgZXhjZXB0IFZhbHVlRXJyb3I6CiAgICAgICAgcGFzcwpwcmludChtYXgoYykpCnByaW50KG1pbihjKSkKCiNodHRwczovL3B0LnN0YWNrb3ZlcmZsb3cuY29tL3EvMzQ2ODk2LzEwMQ==