Skip to content

[Pati] completed lab-functions#21

Open
patriciazapatab wants to merge 1 commit intoIronhack-data-bcn-oct-2023:mainfrom
patriciazapatab:main
Open

[Pati] completed lab-functions#21
patriciazapatab wants to merge 1 commit intoIronhack-data-bcn-oct-2023:mainfrom
patriciazapatab:main

Conversation

@patriciazapatab
Copy link
Copy Markdown

No description provided.

@bripollc
Copy link
Copy Markdown

Pati:)

FELICIDADES!!!! 🙌🏼 I-m-p-e-c-a-b-l-e, hasta completaste el bonus correctamente! Me alegro de que se te dan bien las funciones. Te ahorrarán tiempo y simplificación en tu código:) Sigue así y a por el siguiente lab.

Te dejo solo un pequeño detalle (nada relevante):

  • Write a function that returns the greater of two numbers.
def greater(a,b):
    if a > b:
        return a
    else:
        return b

Tu código es correcto y pasa el test pero se puede optimizar. Estás utilizando una estructura if-elif-else que no es realmente necesaria en este caso, ya que solo con if-else lo tendrías.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants