Last active
September 8, 2019 01:48
-
-
Save MateusDeSousa/646359faafdf5d9ccb04ec4bfc0f8d79 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def funcRafael(x, y): | |
result = (3 * x) ** 2 + y ** 2 | |
return result | |
def funcBeto(x, y): | |
result = 2 * (x ** 2) + (5 * y) ** 2 | |
return result | |
def funcCarlos(x, y): | |
result = (-100 * x) + (y ** 3) | |
return result | |
def funcExec(): | |
x = int(input()) | |
y = int(input()) | |
rafael = funcRafael(x, y) | |
beto = funcBeto(x, y) | |
carlos = funcCarlos(x, y) | |
if beto > rafael and beto > carlos : | |
print("Beto ganhou") | |
if carlos > rafael and carlos > beto: | |
print("Carlos ganhou") | |
if rafael > beto and rafael > carlos: | |
print("Rafael ganhou") | |
def caseTest(): | |
qtdTest = int(input()) | |
for x in range(qtdTest): | |
funcExec() | |
caseTest() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment