📌  相关文章
📜  在线将python转换为java - Python代码示例

📅  最后修改于: 2022-03-11 14:45:52.321000             🧑  作者: Mango

代码示例6
n = int(input())
d = int(input())
a = []
for _ in range(n):
    a.append(int(input()))
k = a[0] // d + 1
for i in range(1, len(a)):
    if i + 1 <= k:
        t = a[i] // d + i + 1
        if k < t:
            k = t
    else:
        break
if k > len(a):
    k = len(a)
print(k)