1 条题解

  • 1
    @ 2026-9-14 19:07:22
    n = int(input())
    
    if n < 10:          # 10本以下:8折
        unit = 40
    elif n < 20:        # 10本及以上且20本以下:7折
        unit = 35
    else:               # 20本及以上:5折
        unit = 25
    
    total = unit * n
    pay = total - (total // 100) * 50  # 每满100元减50元
    print(pay)
    
    
    
    • 1

    信息

    ID
    1360
    时间
    1000ms
    内存
    128MiB
    难度
    8
    标签
    递交数
    36
    已通过
    7
    上传者