官术网_书友最值得收藏!

max() and min()

Using the max() and min() functions, we can find the highest and lowest values from the tuple. These functions allow us to find out information about quantitative data. Let's look at an example:

>>> numbers = (50, 80,98, 110.5, 75, 150.58)
>>> print(max(numbers))
150.58
>>>

Using max(), we will get the highest value in our tuple. Similarly, we can use the min() function:

>>> numbers = (50, 80,98, 110.5, 75, 150.58)
>>> print(min(numbers))
50
>>>

So, here we are getting the minimum value.

主站蜘蛛池模板: 图木舒克市| 汉中市| 新宁县| 焦作市| 新乡市| 广东省| 南木林县| 邯郸市| 河间市| 务川| 巴中市| 花莲市| 武功县| 台南县| 项城市| 铜鼓县| 马鞍山市| 巨野县| 古交市| 德钦县| 安阳县| 神木县| 南靖县| 瓮安县| 股票| 扎鲁特旗| 碌曲县| 大连市| 寻乌县| 渑池县| 宜川县| 河西区| 广东省| 从江县| 左贡县| 吉隆县| 桃园市| 滨海县| 苍南县| 祁东县| 广饶县|