n,*a=list(map(int,open(0).read().split()))

cur=1

ans=a[0]-1

a[0]=1

for x in a:

	if x<=cur:

		pass

	elif x==cur+1:

		cur=x

	else:

		ans+=0--(x-cur-1)//(cur+1)

print(ans)
def main():

	n, *a = list(map(int, open(0).read().split()))

	cur = 1

	ans = a[0] - 1

	a[0] = 1

	for x in a:

		if x <= cur:

			pass

		elif x == cur + 1:

			cur = x

		else:

			ans += 0 - -(x - cur - 1) // (cur + 1)

	print(ans)



if __name__=="__main__":

	main()
n, *a = list(map(int, open(0).read().split()))
cur = 1
ans = a[0] - 1
a[0] = 1
for x in a:
    if x <= cur:
        pass
    elif x == cur + 1:
        cur = x
    else:
        ans += 0 - -(x - cur - 1) // (cur + 1)
print(ans)

def main():
    n, *a = list(map(int, open(0).read().split()))
    cur = 1
    ans = a[0] - 1
    a[0] = 1
    for x in a:
        if x <= cur:
            pass
        elif x == cur + 1:
            cur = x
        else:
            ans += 0 - -(x - cur - 1) // (cur + 1)
    print(ans)


if __name__ == "__main__":
    main()

-n, *a = list(map(int, open(0).read().split())) -cur = 1 -ans = a[0] - 1 -a[0] = 1 -for x in a: -    if x <= cur: -        pass -    elif x == cur + 1: -        cur = x -    else: -        ans += 0 - -(x - cur - 1) // (cur + 1) -print(ans) +def main(): +    n, *a = list(map(int, open(0).read().split())) +    cur = 1 +    ans = a[0] - 1 +    a[0] = 1 +    for x in a: +        if x <= cur: +            pass +        elif x == cur + 1: +            cur = x +        else: +            ans += 0 - -(x - cur - 1) // (cur + 1) +    print(ans) + + +if __name__ == "__main__": +    main()