How do I find the maximum of 2 numbers?

后端 未结 10 1993
借酒劲吻你
借酒劲吻你 2020-12-03 02:22

How to find the maximum of 2 numbers?

value = -9999
run = problem.getscore()

I need to compare the 2 values i.e value and

10条回答
  •  盖世英雄少女心
    2020-12-03 02:42

    Use the builtin function max.

    Example: max(2, 4) returns 4.

    Just for giggles, there's a min as well...should you need it. :P

提交回复
热议问题