import math

n,k = list(map(int, input().split()))

a = list(map(int,input().split()))

for i in range(n):

    if n/(k+((k-1)*i)) <= 1:

        print((i+1))

        break
import math

n,k = list(map(int, input().split()))

a = list(map(int,input().split()))

print((math.ceil(((n-k)/(k-1)))+1))
import math

n, k = list(map(int, input().split()))
a = list(map(int, input().split()))
for i in range(n):
    if n / (k + ((k - 1) * i)) <= 1:
        print((i + 1))
        break

import math

n, k = list(map(int, input().split()))
a = list(map(int, input().split()))
print((math.ceil(((n - k) / (k - 1))) + 1))

-for i in range(n): -    if n / (k + ((k - 1) * i)) <= 1: -        print((i + 1)) -        break +print((math.ceil(((n - k) / (k - 1))) + 1))