poi = float(input("Price of item?"))
if poi <= poi:
lowest_price = poi
if poi >= poi:
largest_price = poi
试图通过用户帮助找到输入的最低和最高价格
poi = float(input("Price of item?"))
if poi <= poi:
lowest_price = poi
if poi >= poi:
largest_price = poi
试图通过用户帮助找到输入的最低和最高价格
Python具有查找列表/数字集的最大值max
的min
内置函数。