peterverebics/CodeNet_Python_118 huggingface dataset:
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))

A, B = MAP()

print(-(-(B-1)//(A-1)))
a,b=map(int,input().split())
print((b+a-3)//(a-1))
a,b = map(int,input().split())
count = 1
plug = 0
if b==1:
    print(0)
    exit()
while 1:
    if plug + a >= b:
        ans = count
        break
    else:
        plug += (a-1)
        count += 1

print(ans)
import math

A, B = list(map(int, input().split()))

result = math.ceil((B - 1) / (A - 1))

print(result)
import sys
ipt = sys.stdin.readline

A, B = map(int, ipt().split())
print(-((1-B)//(A-1)))
import math 

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

if b == 1:
    print(0)
elif a == b:
    print(1)
else:
    print(math.ceil((b-a)/(a-1)+1))
A, B = map(int, input().split())
ans = 0
t = 1
while t < B:
  ans += 1
  t += A-1
print(ans)
A, B = [int(i) for i in input().split()]
result = 1
require_socket = B - A

result += require_socket // (A - 1)
if (require_socket / (A - 1)).is_integer() is False:
    result += 1

print(result)
a, b = map(int,input().split())
print((b + a - 3)//(a - 1))
import math

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

print(math.ceil((b - 1) / (a - 1)))
#k = int(input())
#s = input()
#a, b = map(int, input().split())
#s, t = map(str, input().split())
#l = list(map(int, input().split()))

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

if (b == 1):
    print(0)
    exit()
ans = 0
for i in range(1,1000000000):
    if (i == 1):
        b -= a
    else:
        b -= (a-1)
    ans += 1
    if (b <= 0):
        break
print(ans)
A,B = map(int,input().split())
kuti = 1
kosuu = 0
while kuti < B:
    kuti += A-1
    kosuu += 1
print(kosuu)
# -*- coding:utf-8 -*-
a,b = map(int,input().split())

if  b==1:
    print(0)
elif a >= b:
    print(1)
else:
    SumPowerSocket = a
    NumUsePowerTap = 1
    while True:
        if b > SumPowerSocket:
            SumPowerSocket += a - 1
            NumUsePowerTap += 1
        else:
            print(NumUsePowerTap)
            break
a,b = map(int, input().split())
print((b + a - 3) // (a - 1))
a = input("").split(" ")
a = [int(b) for b in a]
A = a[0]
B = a[1]
n = 1
ans = 0
while n < B:
    ans += 1
    n += A-1
print(ans)
A,B = map(int,input().split())
N = -(-(B-A)//(A-1)) + 1
print(N)
import math
a, b=map(int,input().split())
print(math.ceil((b-1)/(a-1)))
a,b = map(int,input().split())
ans = 0
#最初は電源口１こ
n = 1
while n < b:
    n = n + a - 1
    ans += 1
print(ans)
# coding: utf-8
a, b = map(int, input().split())
ans = 0
sum = 1
while sum < b:
    sum = sum + a - 1
    ans = ans + 1
print(ans)
import math
a, b = list(map(int, input().split()))
print(math.ceil((b - 1) / (a - 1)))
a, b = [int(_) for _ in input().split()]
n = (b-1) // (a-1)
n += b > n*(a-1)+1
print(n)
A, B = map(int,input().split())
import math

print(math.ceil((B-1)/(A-1)))
a,b=map(int,input().split())
ans=0
cnt=1
while cnt<b:
    cnt-=1
    cnt+=a
    ans+=1
print(ans)
'''
INPUT SHORTCUTS
N, K = map(int,input().split())
N ,A,B = map(int,input().split())
string = str(input())
arr = list(map(int,input().split()))
N = int(input())
'''


A, B = map(int,input().split())
ans = 0
if B!=1:
	for i in range(21):
		if ((A*(i+1))-i)>=B:
			ans = i+1 
			break
print(ans)
a, b = map(int, input().split())

if b == 1:
    print(0)
    exit()

ans = a
cnt = 1
for i in range(50):
    if ans >= b:
        print(cnt)
        exit()
    ans += a -1
    cnt += 1
a,b=map(int,input().split())
num=1
ans=0
while(1):
    if num>=b:
        print(ans)
        exit()
    num-=1
    num+=a
    ans+=1
A, B = [int(x) for x in input().split()]
print(-((1 - B) // (A - 1)))
a,b = map(int,input().split())
p = 1
c = 0
while p < b:
    p = p -1 +a
    c+=1
print(c)
a,b  = map(int,input().split())
emp = 1
cnt = 0
while emp < b:
    #print("emp",emp)
    emp = emp-1+a
    #print("emp",emp,cnt)
    cnt += 1

    

print(cnt)
import math
a,b=list(map(int,input().split()))
""" if (b-1)%(a-1)==0:
    print(int((b-1)/(a-1)))
else:
    print(int((b-1)/(a-1))+1)
 """

print(math.ceil((b-1)/(a-1)))
a,b = map(int,input().split())
print(-(-(b-1)//(a-1)))
import sys, itertools, fractions, math, collections, heapq
sys.setrecursionlimit(10**7)
DVSR = 1000000007
def POW(x, y): return pow(x, y, DVSR)
def INV(x, d=DVSR): return pow(x, d - 2, d)
def DIV(x, y, d=DVSR): return (x * INV(y, d)) % d
def LI(): return [int(x) for x in input().split()]
def LF(): return [float(x) for x in input().split()]
def LS(): return input().split()
def II(): return int(input())

a, b = LI()
ans = 0
total = 1
while total < b:
    total += a-1
    ans+=1
print(ans)
a,b=map(int,input().split())
ans=0
p=1
while True:
  if p>=b:
    print(ans)
    exit()
  p+=a-1
  ans+=1
a, b = map(int, input().split())
counter = 0
kuchi = 1

while not (kuchi >= b):
    counter = counter + 1
    kuchi = (kuchi -1) + a

print (counter)
N,K=map(int,input().split())
if ((K-1) % (N-1)) == 0:
  print((K-1)//(N-1))
else:
  print((K-1)//(N-1)+1)
import math

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

temp = math.ceil((b-1)/(a-1))

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

if b==1:
    print(0)
    exit()

i=1
tappu=a

while tappu<b:
    tappu+=(a-1)
    i+=1

print(i)
def main():
    A, B = map(int, input().split())
    C = 1
    ans = 0

    while C < B:
        C -= 1
        C += A
        ans += 1

    print(ans)


if __name__ == "__main__":
    main()
a,b=map(int,input().split())
for i in range(b):
    if (a-1)*i+1>=b:
        print(i)
        exit()
print(b)
A,B = map(int,input().split())
ans = 0
if B>1:
    while B>(A-1)*ans+A:
        ans+=1
    print(ans+1)
else:
    print(ans)
# -*- coding: utf-8 -*-
"""
B - Power Socket
https://atcoder.jp/contests/abc139/tasks/abc139_b

"""
import sys


def solve(A, B):
    total = 1
    used = 0
    while total < B:
        total += (A - 1)
        used += 1
    return used


def main(args):
    A, B = map(int, input().split())
    ans = solve(A, B)
    print(ans)


if __name__ == '__main__':
    main(sys.argv[1:])
a,b = map(int, input().split())

s = 1
cnt = 0
while s<b:
    s += a-1
    cnt += 1

print(cnt)
import math
a,b = map(int,input().split())

ans = math.ceil((b-1)/(a-1))

print(ans)
A,B=map(int,input().split())
count=1
A_sample=A

if B==1:
  print(0)
else:
  while A<B:
    count+=1
    A=(A-1)+A_sample
  print(count)
N,K = [int(x) for x in input().split()]
N = N-1
kosuu = 1
for i in range(1000):
    if kosuu >= K:
        print(i)
        break
    kosuu += N
import sys

sys.setrecursionlimit(10 ** 8)

input = sys.stdin.readline


def main():
    A, B = [int(x) for x in input().split()]
    a = 1

    ans = 0
    while a < B:
        ans += 1
        a -= 1
        a += A

    print(ans)
    
    

if __name__ == '__main__':
    main()
# -*- coding: <encoding name> -*-

import math
a, b = map(int, input().split())
# range = d * 2 + 1
# c == 1 + a * n - n >= b
print(math.ceil((b - 1) / (a - 1)))
a, b = map(int, input().split())
if b==1:
    print(0)
else:
    if b >= a:
        if (b - a) % (a - 1) == 0:
            print((b - a) // (a - 1) + 1)
        else:
            print((b - a) // (a - 1) + 1 + 1)
    else:
        print(1)
A ,B = map(int,input().split())
x = 1
ans = 0
while x < B:
    ans += 1
    x = x - 1 + A
print(ans)
a, b = map(int, input().split())

# 1 + (a-1) * i >= b
for i in range(30):
    if 1 + (a-1) * i >= b:
        print(i)
        exit()
A, B = map(int, input().split())

div, mod = divmod(B - A, A - 1)
div += 1
if mod > 0:
    div += 1
print(div)
A, B = map(int, input().split())
print((B-1) // (A - 1) if (B-1) % (A-1) == 0 else (B-1) // (A - 1) + 1)
a,b=map(int,input().split())

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

sockets = 1
goal = b

ans = 0
while sockets < goal:
    ans += 1
    sockets += a - 1

print(ans)
A, B = [int(x) for x in input().split(" ")]

count = 0
nums = 1
while nums < B:
    nums += A - 1
    count += 1

print(count)
# 標準出力を取得（strデータ）
A, B = input().split()

# A, B を integerに変換
A = int(A)
B = int(B)

# OAタップの数を表す変数の初期値を 1 とする
num = 1


if B == 1:
    num = 0
else:
    while (A - 1) * (num - 1) + A < B:
        num = num + 1

# 結果を出力
print(num)
a,socks = map(int, input().split())
count = 1
ans = 0
while count < socks:
  count += a-1
  ans +=1 
  
print(ans)
A, B = map(int, input().split())
ans = 0
outlet = 1
while outlet < B:
    outlet -= 1
    outlet += A
    ans += 1
print(ans)
import sys
a,b = map(int,input().split())
n = 1
ans = 0
while n < b:
    n += a-1
    ans += 1
print(ans)
import math
p,q= input().split()
a,b =(int(p), int(q))
count = 1

for i in range(math.floor((b/a)**2 + 4)):
    if count < b:
        count += a -1
    else:
        print(i)
        ans = i
        break
a,b=map(int,input().split())
if b==1: print(0)
elif a>=b: print(1)
else:
	x=a+a-1
	t=1
	while x<b:
		t+=1
		x+=a-1
		pass
	print(t+1)
a, b = map(int, input().split())
x = 0
while (a - 1) * x + 1 < b:
    x += 1
print(x)
import math
a, b = map(int,input().split())
print(math.ceil((b-1) / (a-1)))
import math
A,B = map(int, input().split())
print(math.ceil((B-1)/(A-1)))
def resolve():
    a, b = map(int, input().split())
    if b == 1:
        print(0)
    elif b < a:
        print(int(1))
    elif b == a:
        print(int(1))
    else:
        print(int((b-a) / (a - 1))+1 if (b - a) % (a - 1) == 0 else int(b // a + 1))


resolve()
A, B = map(int, input().split())
ans = -(-(B-1) // (A-1))
print(ans)
#139 b
a,b=map(int,input().split())

ans=0
if b!=1:
    b-=a
    ans=1
    while b>0:
        b-=(a-1)
        ans+=1
print(ans)
def main():
	a,b = map(int,input().split())
	ans = 0
	p = 1
	while p < b:
		p += a -1
		ans += 1

	print(ans)


 
if __name__ == '__main__':
	main()
a, b = map(int, input().split())

cnt = 0
p = 1

while p < b:
    p += a - 1
    cnt += 1
    
print(cnt)
#! /usr/bin/env python3
# -*- coding:utf-8 -*-

import math

def calc_num_of_sockets(plug, tap):
    return math.ceil((tap-1)/(plug-1))

def main():
    plug, tap = map(int, input().split())
    print(calc_num_of_sockets(plug, tap))

if __name__ == "__main__":
    try:
        assert calc_num_of_sockets(4, 10) == 3
        assert calc_num_of_sockets(8, 9) == 2
        assert calc_num_of_sockets(8, 8) == 1
    except:
        import traceback
        traceback.print_exc()
        exit()
    main()
a,b = map(int,input().split())

ans = 0
out = 1
while(out < b):
    out -= 1
    out += a
    ans += 1
print(ans)
a, b = map(int, input().split())
ans = 0
tmp = 1
while tmp < b:
    tmp += a-1
    ans += 1
print(ans)
import sys
a,b = map(int,input().split())
c = 2
if b == 1:
    print(0)
    sys.exit()
if a >= b:
    print(1)
    sys.exit()
R = False
x = 2*a - 1
while R == False:
    if x >= b:
        R = True
    else:
        x += a-1
        c += 1
print(c)
A, B = map(int, input().split())

ans = 1
i = 0
while ans < B:
    ans += A - 1
    i += 1

print(i)
a, b=map(int, input().split())
ans=1
kuti=a
while(1):
  if b==1:
    print(0)
    break
  if kuti>=b:
    print(ans)
    break
  else:
    kuti+=a-1
    ans+=1
a,b=map(int,input().split())
k=1
for i in range(21):
    if k<b:
        k+=a-1
    else:
        print(i)
        break
A,B = map(int, input().split())
k = 0
ans = 1
while ans < B:
  ans = ans - 1 + A
  k += 1

print(k)
A,B = map(int,input().split())
 
for i in range(100):
  if (i*A -(i-1)) >= B:
    break
print(i)
A,B=map(int,input().split())

if (B-1)%(A-1)==0:
  print(int((B-1)/(A-1)))
else:
  print(int((B-1)//(A-1)+1))
a,b=map(int,input().split())
ans=(b-1)//(a-1)
if (b-1)%(a-1)!=0:
  ans+=1
print(ans)
a, b = map(int, input().split())
print((b + a - 3) // (a - 1))
A, B = map(int, input().split())
if B == 1:
    print(0)
    quit()
else:
    i = 1
    while (A - 1) * i + 1 < B:
        i += 1
    print(i)
a,b=map(int,input().split())
print(-(-(b-1)//(a-1)))
A, B = map(int, input().split())

calc = (B-1)/(A-1)

if calc % 1 == 0:
    print(int(calc))
else:
    print(int(calc) + 1)
tap_socket_num, required_socket = map(int, input().split())

if required_socket <= 1:
    print(0)
elif required_socket <= tap_socket_num:
    print(1)
else:
    n = (required_socket-tap_socket_num)%(tap_socket_num - 1)
    if n == 0:
        print((required_socket - tap_socket_num)//(tap_socket_num - 1) + 1)
    else:
        print((required_socket - tap_socket_num)//(tap_socket_num - 1) + 2)
A,B=map(int,input().split())
cnt=0
while True:
  if (A-1)*cnt+1>=B:
    break
  cnt+=1
print(cnt)
a,b=map(int,input().split())
import math
ans=math.ceil((b-1)/(a-1))
print(ans)
a,b = map(int,input().split())
soc=1
for i in range(1,21):
	if i*(a-1)+1 >= b:
		soc = i
		break
if b==1:
	soc=0

print(soc)
a, b = map(int, input().split())
sockets = 1
cnt = 0
while True:
    if sockets >= b: break
    sockets += a - 1
    cnt += 1
print(cnt)
A,B=map(int,input().split())
c=0
while (A*c-c+1)<B:
  c+=1
print(c)
x = input().split()
A, B = int(x[0]), int(x[1])
n = 1
t = 0
while n < B:
  n += A - 1
  t += 1
print(t)
def resolve():
    a,b=map(int, input().split())
    ans=0
    misiyou=1
    while  misiyou<b:
        ans+=1
        misiyou+=a-1
    print(ans)
resolve()
A,B = map(int,input().split())
ruisekiwa = [1]
i = 0
while ruisekiwa[i] < B:
  ruisekiwa.append(ruisekiwa[i] + A - 1)
  i += 1
print(i)
import math

A, B = map(int, input().split(' '))
add = A - 1
res = math.ceil((B-1) / add)
print(res)
import math
A, B = map(int,input().split())
print(math.ceil((B - 1) / (A - 1)))
import math

A, B = [int(i) for i in input().split()]

ans = math.ceil((B-1)/(A-1))

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

print(ans)
import sys
input = sys.stdin.readline

# B - Power Socket
a, b = map(int, input().split())

if b == 1:
	print(0)
else:
	sockets = a
	ans = 1
	
	while sockets < b:
		sockets += a- 1
		ans += 1

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

ans = 0
num = 1
while num < b:
    num += a - 1
    ans += 1

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

ans = a
if b == 1:
  print(0)
  exit()

  
for i in range(10000):
  if ans >= b:
    print(i+1)
    exit()

  else:
    ans += a -1
import sys
from math import ceil, floor, sqrt, sin, cos, pi
from itertools import accumulate, permutations, combinations
from fractions import gcd # 最大公約数
from collections import deque, Counter
from operator import itemgetter
from heapq import heappop,heappush
sys.setrecursionlimit(10**7)
def lcm(x, y): return ((x * y) // gcd(x, y)) # 最小公倍数
# list(map(int, input().split()))

a, b = map(int, input().split())
ans = 0
cnt = 1
while True:
    if cnt >= b:
        print(ans)
        sys.exit()
    cnt = cnt + a - 1
    ans += 1
import math


def resolve():
    A, B = map(int, input().split())
    print(math.ceil((B - 1) / (A - 1)))


if __name__ == "__main__":
    resolve()
A,B=map(int,input().split())
x = 0
y = 1
while y <B:
    y+=(A-1)
    x+=1
print (x)
A, B = map(int, input().split())
N = 1
i = 0
while N < B:
  N += A-1
  i += 1  
print(i)
a,b = map(int,input().split())
ans = 0
cur = 1
while cur < b:
  cur = cur - 1 + a
  ans += 1
print(ans)
A, B = map(int, input().split())
if (B-1) % (A-1) == 0:
    n = (B-1) // (A-1)
else:
    n = (B-1) // (A-1) + 1
print(n)
A,B=map(int,input().split())
print(1-(A-B)//~-A)
a, b = map(int, input().split())
ans = 1
cnt = 0
while ans < b:
  ans += a - 1
  cnt += 1
print(cnt)
m, n = input().split()
m, n = int(m), int(n)
 
tot = 0
a = 1
while a<n:
  a-=1
  a+=m
  tot+=1
 
print(tot)
#139_B
a, b = map(int, input().split())
print(-(-(b - a) // (a - 1)) + 1)
a,b=map(int,input().split())
n=-1
while True:
  n+=1
  if n*(a-1)>=b-1:
    print(n)
    break
A,B=map(int,input().split())
import math
print(math.ceil((B-1)/(A-1)))
a, b = list(map(int, input().split()))

ans = (b-1) // (a - 1) if (b-1)% (a-1) == 0 else (b-1) // (a-1) + 1
print(ans)
a,b = map(int,input().split())
c = 1
count = 0
while  c < b:
    c += a-1
    count += 1

print(count)
A, B = map(int,input().split())
if B == 1:
    print(0)
else:
    num = A
    ans = 1
    while num < B:
        num += A-1
        ans += 1
    print(ans)
a,b = map(int,input().split())
if (b-1)%(a-1)==0:
   print((b-1)//(a-1))
else:
    print((b-1)//(a-1) +1)
a,b = map(int ,input().split())
n =0
l =1

while l < b:
    l = l+a-1
    n +=1
        
print(n)
a, b = map(int, input().split())
if b == 1:
    print(0)
    exit(0)
for i in range(10000):
    if a + i * a - i >= b:
        print(1 + i)
        break
import sys
d = list(map(int,input().split()))
A = d[0]
B = d[1]
cnt = 0
while True:
    #A口がcnt個ある。cntが1のときA*1口
    #cntが2以上のとき、
    if A*cnt - cnt +1 >= B:
        print(cnt)
        sys.exit(0)
    cnt +=1
A,B = map(int, input().split())

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


print(ans)
A,B = map(int,input().split())
out = 1
count = 0
while out < B:
    out -= 1
    out += A
    count += 1
print(count)
a, b = map(int, input().split())

ans = 0
cnt = 1

while cnt < b:
    cnt += a - 1
    ans += 1

print(ans)
import math
import sys

stdin = sys.stdin

ns = lambda: stdin.readline().rstrip()
ni = lambda: int(stdin.readline().rstrip())
nm = lambda: map(int, stdin.readline().split())
nl = lambda: list(map(int, stdin.readline().split()))
mod = 10**9 + 7 
sys.setrecursionlimit(1000010)

A,B  = nm()

s = A - 1
print(((B-1)+s -1)//s )
#入力:N,M(int:整数)
def input2():
	return map(int,input().split())

a,b=input2()
count=1
if b<=1:
	print(0)
else:
	for i in range(1,21):
		count=count-1+a
		if count>=b:
			print(i)
			break
import sys
input = sys.stdin.readline
sys.setrecursionlimit(10 ** 7)

A, B = map(int, input().split())

answer = 0
x = 1
while B > x:
    x += (A-1)
    answer += 1
print(answer)
A,B = map(int, input().split())
if B == 1:
  print(0)
  exit(0)
  
sumA = A
if sumA >= B:
  print(1)
  exit(0)

sumA = sumA + A - 1
for i in range(2,100):
  if sumA >= B:
    print(i)
    break
  else:
    sumA = sumA + A - 1
a,b = map(int,input().split())
sum = 1
count = 0
while sum < b :
  sum += a - 1
  count += 1
print (count)
def main():
    A,B = map(int, input().split())
    aki = 1
    cnt = 0

    while aki < B:
        aki -=1
        aki += A
        cnt += 1

    print(cnt)


if __name__ == '__main__':
    main()
a, b = map(int, input().split())
res=-(-(b-1)//(a-1))
print(res)
a, b = map(int, input().split())
tap = 0
sasikomi = 1

while sasikomi < b:
    sasikomi += a-1
    tap += 1
print(tap)
A, B = [int(i) for i in input().split()]

for n in range(21):
    socket = A*n-n+1
    if(socket >= B):
        print(n)
        break
a,b=map(int,input().split())
ans=0
sum=1
while sum<b:
    sum+=a-1
    ans+=1
print(ans)
a, b = map(int, input().split())
print(0--(b-1)//(a-1))
a, b = map(int, input().split())

# b -= a
# counter = 1
# while b > 0:
#     b -= a - 1
#     counter += 1

# print(counter)

sum_tap = 1

for i in range(100):
    if sum_tap >= b:
        print(i)
        break
    sum_tap += a - 1
A,B=map(int,input().split())
for i in range(21):
    if 1+i*A-i>=B:
        print(i)
        exit()
def main():
    A, B = (int(i) for i in input().split())
    print(0--(B-1)//(A-1))


if __name__ == '__main__':
    main()
a, b = map(int, input().split())
count = 0
while a * count - (count - 1) < b:
  count += 1

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

if b==1:
    ans=0
    
else:
    ans=int((b-2)/(a-1))+1

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

if b != 1:
  for i in range(b+1):
    if a + (a - 1) * i >= b:
      print(i + 1)
      break
else:
  print(0)
import math
A,B=map(int,input().split())
print(1+math.ceil((B-A)/(A-1)))
import math
def powerSocket(a, b):
	return math.ceil((b-1)/(a-1))
a, b = map(int, input().split())
print(powerSocket(a, b))
A,B = map(int, input().split())
insert = 1
cnt = 0
while(insert < B):
  insert = insert - 1 + A
  cnt += 1
    
print(cnt)
a, b = map(int, input().split())
con = 1
ans = 0

while con < b:
    con += a - 1
    ans += 1

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

while socket < b:
    socket += a-1
    ans += 1

print(ans)
# -*- coding: utf-8 -*-
import math

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

a, b = a-1, b-1
print(math.ceil(b/a))
def resolve():
    A, B = [int(x) for x in input().split(" ")]
    n = 0
    t = 1
    while t < B:
        t -= 1
        t += A
        n += 1
    print(n)
resolve()
a, b = map(int, input().split())
if b == 1:
  print(0)
else:
  ans = 1
  while True:
    if ans * a - (ans-1) >= b:
   	  break
    ans += 1
  print(ans)
a,b=map(int,input().split())
con=1
ans=0
while con<b:
    con+=a-1
    ans+=1
print(ans)
import math
A,B = map(int,input().split())
n = math.ceil((B-1)/(A-1))
print(n)
a,b=map(int,input().split())
kuti=1
hituyou=0
while kuti<b:
  kuti=kuti+a-1
  hituyou=hituyou+1
print(hituyou)
A, B = map(int, input().split())
count = 0
outlet = 1
while outlet < B :
    count += 1
    outlet += A - 1
print(count)
A,B = map(int,input().split())

ans = 1
cnt = 0
while True:
    cnt += 1
    if ans >= B:
        break
    ans += A-1

print(cnt-1)
a,b = map(int,input().split())
n = (b-1)/(a-1)
print(-int((-n)//1))
a, b = map(int, input().split())
n = a
count = 1

if b == 1:
  print(0)
else:
  while n < b:
    n += a-1
    count += 1
  print(count)
a, b = map(int, input().split())
c = (b - 1) / (a - 1)
if c % 1 == 0:
    print((b - 1) // (a - 1))
else:
    print((b - 1) // (a - 1) + 1)
import sys
from collections import defaultdict
readline = sys.stdin.buffer.readline
#sys.setrecursionlimit(10**8)


def geta(fn=lambda s: s.decode()):
    return map(fn, readline().split())


def gete(fn=lambda s: s.decode()):
    return fn(readline().rstrip())


def main():
    a, b = geta(int)

    tot = 1
    ans = 0
    while tot < b:
        ans += 1
        tot += a - 1

    print(ans)


if __name__ == "__main__":
    main()
a, b = list(map(int, input().split(' ')))

socket = 1
count = 0
while(True):
    if socket >= b:
        break
    count += 1
    socket += (a - 1)


print(count)
a, b =map(int, input().split())
d, q = divmod(b-1,a-1)
if q == 0:
  print(d)
else:
  print(d+1)
line = input().split(" ")
a = int(line[0])
b = int(line[1])

# a + (n - 1) * (a - 1) >= b
# n * (a - 1) + 1 >= b
# n >= (b - 1)/(a - 1)

n = (b - 1)/(a - 1)

if n == int(n):
  print(int(n))
elif n >= int(n):
  print(int(n) + 1)
#B Power Socket
import math
a,b=map(int,input().split())
out=1
ans=0
while out<b:
    out-=1
    out+=a
    ans+=1
print(ans)
import math
a, b = map(int,input().split())

b -= a
print(math.ceil(b/(a-1))+1)
a,b= map(int,input().split())
import math
print(math.ceil((b-a)/(a-1))+1)
a, b = input().split(' ')
c = int(a)
d = int(b)

for i in range(21):
  if d <= c*i-(i-1):
    print(str(i))
    break
A, B = map(int, input().split())
count = 1
i = A
while i < B:
    count += 1
    i = count * A - (count - 1)

print(count)
# coding: utf-8
 
a,b=list(map(int,input().split()))
 
mouse_tot = a
mouse_cnt = 1
wa = a-1
 
while mouse_tot <  b:
    mouse_tot += wa
    mouse_cnt += 1
 
print(mouse_cnt)
A,B=map(int,input().split())
for i in range(20):
  if i==0 and A>=B:
    break
  if i>0 and (i+1)*A-1>=B:
    break
print(i+1)
a,b=map(int,input().split())
c=1
d=0
while c<d:
    d+=1
    c=a*c-(d-1)
print(d)
A,B=map(int,input().split())
if A>=B:
    print(1)
else:
    print(B//A+1)
import numpy as np
from functools import reduce
from operator import add,sub,mul,truediv
from fractions import gcd

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


ans = 1
x = a

while x < b:
    ans = ans + 1
    x = x + a-1

print(ans)
A, B = [int(i) for i in input().split()]
result = 1
require_socket = B - A

if B == 1:
    print(0)
else:
    result += require_socket // A
    if (require_socket / A).is_integer() is False:
        result += 1

print(result)
import math
A, B = map(int, input().split())
print(1 if A ==B else math.ceil(B/A))
a, b = map(int, input().split())
ans = 1
while True:
  if ans * a >= b:
    break
  ans += 1
print(ans)
a,b = map(int, input().split())
res = 0
c = 1
while c < b:
  c += a - 1
  res += 1
  print(res)