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



num = 1

ans = 0



if b == 1:

    print((0))

    exit()



while True:

    num += a - 1

    ans += 1

    if num >= b:

        break



print(ans)
a, b = list(map(int, input().split()))



ans = 0

cnt = 1



while cnt < b:

    cnt += a - 1

    ans += 1



print(ans)
a, b = list(map(int, input().split()))
num = 1
ans = 0
if b == 1:
    print((0))
    exit()
while True:
    num += a - 1
    ans += 1
    if num >= b:
        break
print(ans)

a, b = list(map(int, input().split()))
ans = 0
cnt = 1
while cnt < b:
    cnt += a - 1
    ans += 1
print(ans)

-num = 1 -if b == 1: -    print((0)) -    exit() -while True: -    num += a - 1 +cnt = 1 +while cnt < b: +    cnt += a - 1 -    if num >= b: -        break