Problem:


Score : 200 points

Problem Statement

Takahashi's house has only one socket.

Takahashi wants to extend it with some number of power strips, each with A sockets, into B or more empty sockets.

One power strip with A sockets can extend one empty socket into A empty sockets.

Find the minimum number of power strips required.

Constraints

All values in input are integers.

2 \leq A \leq 20

1 \leq B \leq 20

Input

Input is given from Standard Input in the following format:

A B

Output

Print the minimum number of power strips required.

Sample Input 1

4 10

Sample Output 1

3

3 power strips, each with 4 sockets, extend the socket into 10 empty sockets.

Sample Input 2

8 9

Sample Output 2

2

2 power strips, each with 8 sockets, extend the socket into 15 empty sockets.

Sample Input 3

8 8

Sample Output 3

1



Sample input:
4 10


Sample output:
3

Submission status: Wrong Answer

Solution code:
a,b = map(int, input().split())
if b == 1:
  ans = 0
else:
  for i in range(11):
    c = a*i
    if c >= b:
      ans = i
      break
print(ans)

Submission status: Wrong Answer

Solution code:
a,b=[int(x) for x in input().split()]
ans=1
for i in range(1,30):
    c=a*1+(a-1)*(i-1)
    if c>=b:
        ans=i
        break
print(ans)

Submission status: Wrong Answer

Solution code:
a,b = map(int, input().split())
for i in range(11):
  c = a*i
  if c >= b:
    ans = i
    break
print(ans)

Submission status: Wrong Answer

Solution code:
import sys, re
from math import ceil, floor, sqrt, pi, factorial, gcd
from copy import deepcopy
from collections import Counter, deque
from heapq import heapify, heappop, heappush
from itertools import accumulate, product, combinations, combinations_with_replacement
from bisect import bisect, bisect_left, bisect_right
from functools import reduce
from decimal import Decimal, getcontext
# input = sys.stdin.readline 
def i_input(): return int(input())
def i_map(): return map(int, input().split())
def i_list(): return list(i_map())
def i_row(N): return [i_input() for _ in range(N)]
def i_row_list(N): return [i_list() for _ in range(N)]
def s_input(): return input()
def s_map(): return input().split()
def s_list(): return list(s_map())
def s_row(N): return [s_input for _ in range(N)]
def s_row_str(N): return [s_list() for _ in range(N)]
def s_row_list(N): return [list(s_input()) for _ in range(N)]
def lcm(a, b): return a * b // gcd(a, b)
sys.setrecursionlimit(10 ** 6)
INF = float('inf')
MOD = 10 ** 9 + 7
num_list = []
str_list = []

def main():
    a, b = i_list()
    if b == 0:
        print(0)
    else:
        i = 1
        while (a + (a - 1) * (i - 1) < b):
            i += 1
        print(i)
        

if __name__ == '__main__':
    main()

Submission status: Wrong Answer

Solution code:
import sys, re
from math import ceil, floor, sqrt, pi, factorial, gcd
from copy import deepcopy
from collections import Counter, deque
from heapq import heapify, heappop, heappush
from itertools import accumulate, product, combinations, combinations_with_replacement
from bisect import bisect, bisect_left, bisect_right
from functools import reduce
from decimal import Decimal, getcontext
# input = sys.stdin.readline 
def i_input(): return int(input())
def i_map(): return map(int, input().split())
def i_list(): return list(i_map())
def i_row(N): return [i_input() for _ in range(N)]
def i_row_list(N): return [i_list() for _ in range(N)]
def s_input(): return input()
def s_map(): return input().split()
def s_list(): return list(s_map())
def s_row(N): return [s_input for _ in range(N)]
def s_row_str(N): return [s_list() for _ in range(N)]
def s_row_list(N): return [list(s_input()) for _ in range(N)]
def lcm(a, b): return a * b // gcd(a, b)
sys.setrecursionlimit(10 ** 6)
INF = float('inf')
MOD = 10 ** 9 + 7
num_list = []
str_list = []

def main():
    a, b = i_list()
    i = 1
    while (a + (a - 1) * (i - 1) < b):
        i += 1
    print(i)
        

if __name__ == '__main__':
    main()

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())

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

ans = a
cnt = 1
for i in range(50):
    if ans >= b:
        print(cnt)
        exit()
    ans += a -1
    cnt += 1

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())

ans = a
cnt = 1
for i in range(50):
    if ans > b:
        print(cnt)
        exit()
    ans += a -1
    cnt += 1

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())

ans = a
cnt = 1
for i in range(50):
    if ans >= b:
        print(cnt)
        exit()
    ans += a -1
    cnt += 1

Submission status: Wrong Answer

Solution code:
import sys
input = lambda: sys.stdin.readline().rstrip() 
sys.setrecursionlimit(10**7)
INF = 10**20
def I(): return int(input())
def F(): return float(input())
def S(): return input()
def LI(): return [int(x) for x in input().split()]
def LI_(): return [int(x)-1 for x in input().split()]
def LF(): return [float(x) for x in input().split()]
def LS(): return input().split()

def resolve():
    A, B = LI()

    ans = (B - 1) // A + 1
    print(ans)

if __name__ == '__main__':
    resolve()

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
c = (b-1)//a + 1
if b == 1:
	print(0)
else:
	print(c)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
c = (b-1)//a + 1
print(c)

Submission status: Wrong Answer

Solution code:
a,b = map(int, input().split())

count = 1
total = a

if total >= b:
    print(count)
else:
    while True:
        total += (a-1)
        count += 1
        if total >= b:
            print(count)
            break

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())
for i in range(1,21):
    if i*a-(i-1) >= b:
        print(i)
        break

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())
for i in range(2,21):
    if i*a-(i-1) >= b:
        print(i)
        break

Submission status: Wrong Answer

Solution code:
a, b = list(map(int, input().split()))
ans = b//a
if ans * a < b:
    ans += 1
print(ans)

Submission status: Wrong Answer

Solution code:
a,b = list(map(int, input().split()))
x,y = divmod(a,b)
print(x+y)

Submission status: Wrong Answer

Solution code:
import math

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

print(math.ceil(B / A))

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
print((a+b-2)//(a-1))

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
print((a+b-2)//a)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
print((a+b-1)//a)

Submission status: Wrong Answer

Solution code:
s = list(map(int, input().split()))
a = s[0]
b = s[1]

for i in range(b):
    if(i == 0):
        continue
    elif(a + (a-1)*(i-1)) >= b:
        print(i)
        break

Submission status: Wrong Answer

Solution code:
A,B = map(int,input().split())
if B<=A:
    answer = 1
else:
    tap = 2
    while True:
        if tap*A-tap+1 >= B:
            answer = tap
            break
        else:
            tap += 1
print(answer)

Submission status: Wrong Answer

Solution code:
def Input():
    return map(int, input().split(" "))

def main():
    a, b = Input()
    x = b // a
    if b % a:
        print(x + 1)
    else:
        print(x)

main()

Submission status: Wrong Answer

Solution code:
a,b= map(int,input().split())
for i in range(b):
  if 1+(a-1)*i >= b:
    print(i)

Submission status: Wrong Answer

Solution code:
A, B = [int(x) for x in input().split()]
print(-(-B//A))

Submission status: Wrong Answer

Solution code:
import math
a, b = map(int, input().split())
n = a
ans = 1
while n<b:
    for i in range(1, n+1):
        n += a
        ans += 1
        if n>=b:
            break
print(ans)

Submission status: Wrong Answer

Solution code:
# coding: utf-8
import math
a, b = map(int, input().split())
ans = 1
now_consent = a
plusplug = a - 1
if a >= b:
    print(1)
elif a < b:
    other = b - a
    ans += math.ceil(other / plusplug)
    print(ans)

Submission status: Wrong Answer

Solution code:
# coding: utf-8
import math

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

Submission status: Wrong Answer

Solution code:
# coding: utf-8
import math

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

Submission status: Wrong Answer

Solution code:
# coding: utf-8
import math

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

Submission status: Wrong Answer

Solution code:
# coding: utf-8
import math

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

Submission status: Wrong Answer

Solution code:
# coding: utf-8
import math

a, b = map(int, input().split())
if a >= b:
    print(1)
else:
    ans = math.ceil(b / a)
    if b <= ans * a:
      print(ans)
    else:
      print(ans+1)

Submission status: Wrong Answer

Solution code:
# coding: utf-8
import math

a, b = map(int, input().split())
if a >= b:
    print(1)
else:
    print(math.ceil(b / a))

Submission status: Wrong Answer

Solution code:
a,b = map(int, input().split())
count = 0
if b == 1:
  print(0)
else:
  while True:
    if b <= (a-1)*count + a:
      break
    count += 1
  print(count)

Submission status: Wrong Answer

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

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

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


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

# 結果を出力
print(num)

Submission status: Wrong Answer

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

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

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


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

# 結果を出力
print(num)

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())

if b == 1:
  print("0")
elif b % a == 0:
  print((b//a))
else:
  print(((b//a)+1))

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())

if b % a == 0:
  print((b//a))
else:
  print(((b//a)+1))

Submission status: Wrong Answer

Solution code:
a,b = map(int, input().split())
count = 1
while True:
  if b <= (a-1)*(count-1) + a:
    break
  count += 1
print(count)

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())
n = (b-1)//(a-1)+1
print(n)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
i=1
while a+(i-1)*(a-1)<b:
    i+=1
print(i)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
i,count=1,a
while count<b:
    count+=(a-1)
    i+=1
print(i)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
i,count=1,a
while count<b:
    count+=a
    i+=1
print(i)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
i=1
while a+(i-1)*(a-1)<b:
  i+=1
print(i)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
print((b-1)//a+1)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())
cnt = 0; tap = 0
while True:
    cnt += 1
    tap += (a-1)
    if tap + 1 >= b:
        break
    if tap + a >= b:
        cnt += 1
        break
print(cnt)

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())
cnt = 0; tap = 0
while True:
    cnt += 1
    tap += (a-1)
    if tap + 1 == b:
        break
    if tap + a >= b:
        cnt += 1
        break
print(cnt)

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())
cnt = 0; tap = 0
while True:
    cnt += 1
    if a == b:
        break
    tap += (a-1)
    if tap + a >= b:
        cnt += 1
        break
print(cnt)

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())
cnt = 0; tap = 0
while True:
    if a == b:
        break
    cnt += 1
    tap += (a-1)
    if tap + a >= b:
        cnt += 1
        break
print(cnt)

Submission status: Wrong Answer

Solution code:
a,b=input().split()
a=int(a)
b=int(b)
i=0
sum=0
while True:
    if i==0:
        b=b-a
        sum+=1
        i+=1
    elif b<=0:
        print(sum)
        break
    else:
        b=b-a+1
        sum+=1
        i+=1

Submission status: Wrong Answer

Solution code:
n, x = map(int, input().split())
print((x + n - 1) // n)

Submission status: Wrong Answer

Solution code:
x, n = map(int, input().split())
print((n + x -1) // x)

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())
if b%a==0:
    print(b//a)
else:
    print(b//a+1)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
x = b // a
if b % a == 0:
    print(x)
else:
    print(x + 1)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())

if b==1:
  print(0)
if b>1:
  x=0
  ans=0
  while x<b:
    ans+=1
    x+=a
  print(ans)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())

if b==1:
  print(1)
if b>1:
  if b%a==0:
    print(b//a)
  else:
    print(b//a+1)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())

if b==1:
  print(0)
if b>1:
  if b%a==0:
    print(b//a)
  else:
    print(b//a+1)

Submission status: Wrong Answer

Solution code:
from math import ceil

inputs = input()
a = int(inputs.split(" ")[0])
b = int(inputs.split(" ")[1])
print(ceil((b + 1) / (a + 1)))

Submission status: Wrong Answer

Solution code:
from math import ceil

inputs = input()
a = int(inputs.split(" ")[0])
b = int(inputs.split(" ")[1])
print(ceil((b + 1) / (a - 1)))

Submission status: Wrong Answer

Solution code:
inputs = input()
a = int(inputs.split(" ")[0])
b = int(inputs.split(" ")[1])
print(int((b + 1) / (a - 1)))

Submission status: Wrong Answer

Solution code:
a,b = map(int, input().split())
s = 1
for i in range(1,(b//a)+2):
    s += (a-1)
    if b <= s:
        print(i)
        break

Submission status: Wrong Answer

Solution code:
A,B=map(int,input().split())
n=0
count=0
while n<=B:
    n+=(A-1)
    count+=1
print(count)

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())
ans = 1
tmp = a
while tmp<b:
    tmp += a-1
    ans += 1
print(ans)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())

if b>=a:
  if b%a!=0:
    print(b//a+1)
  else:
    print(b//a)
elif b== 1:
  print(0)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())

if b>=a:
  if b%a!=0:
    print(b//a+1)
  else:
    print(b//a)
else:
  print(1)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())

if b%a!=0:
  print(b//a+1)
else:
  print(b//a)

Submission status: Wrong Answer

Solution code:
import sys, bisect, math, itertools, string, queue, copy
# import numpy as np
# import scipy
# from collections import Counter,defaultdict,deque
# from itertools import permutations, combinations
# from heapq import heappop, heappush
# # input = sys.stdin.readline
# sys.setrecursionlimit(10**8)
mod = 10**9+7
def inp(): return int(input())
def inpm(): return map(int,input().split())
def inpl(): return list(map(int, input().split()))
def inpls(): return list(input().split())
def inplm(n): return list(int(input()) for _ in range(n))
def inplL(n): return [list(input()) for _ in range(n)]
def inplT(n): return [tuple(input()) for _ in range(n)]
def inpll(n): return [list(map(int, input().split())) for _ in range(n)]
def inplls(n): return sorted([list(map(int, input().split())) for _ in range(n)])

a, b = inpm()
tmp = a
if(b == 1):
    print(0)
    exit
ans = 1
while(b > tmp):
    tmp += a - 1
    ans += 1
print(ans)

Submission status: Wrong Answer

Solution code:
import sys, bisect, math, itertools, string, queue, copy
# import numpy as np
# import scipy
# from collections import Counter,defaultdict,deque
# from itertools import permutations, combinations
# from heapq import heappop, heappush
# # input = sys.stdin.readline
# sys.setrecursionlimit(10**8)
mod = 10**9+7
def inp(): return int(input())
def inpm(): return map(int,input().split())
def inpl(): return list(map(int, input().split()))
def inpls(): return list(input().split())
def inplm(n): return list(int(input()) for _ in range(n))
def inplL(n): return [list(input()) for _ in range(n)]
def inplT(n): return [tuple(input()) for _ in range(n)]
def inpll(n): return [list(map(int, input().split())) for _ in range(n)]
def inplls(n): return sorted([list(map(int, input().split())) for _ in range(n)])

a, b = inpm()
tmp = a
ans = 1
while(b > tmp):
    tmp += a - 1
    ans += 1
print(ans)

Submission status: Wrong Answer

Solution code:
import math
a, b = list(map(int, input().split()))
if a > b:
  print(1)
else:
	print(math.ceil(b/a))

Submission status: Wrong Answer

Solution code:
import math
a, b = list(map(int, input().split()))
print(math.ceil(b/a))

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())

ans=[]
for i in range(20):
  if b<=a+(a-1)*i:
    ans.append(i+1)

print(min(ans))

Submission status: Wrong Answer

Solution code:
A, B = [int(x) for x in input().split()]
print(-(-B//A))

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())

socket = a
cnt = 1
while socket < b:
  socket += (a-1)
  cnt += 1
  
print(cnt)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())

cnt = 1
while a < b:
  a += a
  cnt += 1
  
print(cnt)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
 
n=1
while (a-1)*n+1<b:
  n+=1
  
print(n)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())

c=1
num=a
while num<b:
  num+=a
  num-=1
  c+=1
  
print(c)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
inc=a
ans=1
while inc<b:
  inc+=a-1
  ans+=1
print(ans)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
ans = b//a

if b % a == 0:
  print(ans)
else:
  print(ans+1)

Submission status: Wrong Answer

Solution code:
a,b=map(int, input().split())
c="必要な電源タップ数は"
d="個です。"
count=0
total=0
while True:
    
#    total+=a
    
#    if total<b:
#        total-=1
#        count+=1
#    else:
#        break
    if total >= b:
        break
    total += (a-1)
    count+=1
print(count)

Submission status: Wrong Answer

Solution code:
a,b=map(int, input().split())
c="必要な電源タップ数は"
d="個です。"
count=0
total=0
while True:
    total+=a
    if total<b:
        total-=1
        count+=1
    else:
        break
print(count)

Submission status: Wrong Answer

Solution code:
import math
A,B = map(int,input().split())
print(math.ceil((B+1)/(A-1)))

Submission status: Wrong Answer

Solution code:
import math
A,B = map(int,input().split())
print(math.ceil(B/(A-1)))

Submission status: Wrong Answer

Solution code:
import math
A,B = map(int,input().split())
print(math.floor(B/(A-1)))

Submission status: Wrong Answer

Solution code:
A,B = map(int,input().split())
if(A%B == 0):
    print(B//A)
else:
    print(B//A+1)

Submission status: Wrong Answer

Solution code:
A,B = map(int,input().split())
if(A%B == 0):
    print(B/A)
else:
    print(B//A+1)

Submission status: Wrong Answer

Solution code:
A,B=map(int,input().split())

s=0

while B-(A-1)*s+1>0:
     s+=1
print(s)

Submission status: Wrong Answer

Solution code:
import math
a,b = map(int, input().split())
if b == 1:
    print(1)
else:
    print(math.ceil(b/a))

Submission status: Wrong Answer

Solution code:
import math
a,b = map(int, input().split())
print(math.ceil(b/a))

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())

cur = 1
ans = 0

while cur < b:
    cur += a
    ans +=1

print(ans)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())

print((b - 1) // a + 1)

Submission status: Wrong Answer

Solution code:
kutisuu,add_kosuu = list(map(int,input().split()))
 
count = add_kosuu/(kutisuu-1)
if add_kosuu % (kutisuu-1) >= 2:
    count += 1
if add_kosuu < 2:
  print(0)
else:
	print(int(count))

Submission status: Wrong Answer

Solution code:
kutisuu,add_kosuu = list(map(int,input().split()))


count = add_kosuu/(kutisuu-1)
if add_kosuu % (kutisuu-1) >= 2:
    count += 1

print(int(count))

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())
for i in range(20):
    if a +(a-1)*i >=b:
        print(i+1)
        break

Submission status: Wrong Answer

Solution code:
A, B = map(int, input().split())

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

print(cnt)

Submission status: Wrong Answer

Solution code:
A, B = map(int, input().split())

cnt = 1
while True:
    if (A*cnt)-(cnt-1) >= B:
        break
    cnt += 1

print(cnt)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
p=1
ans=0
while p<=b:
    p+=a
    ans+=1
print(ans)

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())

num = 1
while True:
  if a * num - (num-1) >= b:
    break
    
  num += 1
  
print(num)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
# a：電源タップ1個あたりの口数
# b：増やしたいタップ口数

def calc(a, b):
    ans_list = [a]
    add_tap = a

    for i in range(19):
        add_tap += a-1
        ans_list.append(add_tap)

    for i, value in enumerate(ans_list):
        if value >= b:
            print(i+1)
            break
            
calc(a, b)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
# a：電源タップ1個あたりの口数
# b：増やしたいタップ口数

ans_list = [a]
add_tap = a

for i in range(20):
    add_tap += a-1
    ans_list.append(add_tap)
    
for i, value in enumerate(ans_list):
    if value >= b:
        print(i+1)
        break

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
if a == b:
    print(1)
else:
    print((b//a)+1)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
ans = b // a
if b % a != 0:
    ans += 1
print(ans)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
for i in range(b):
    if  a * i == b:
        print(i)
        exit()

Submission status: Wrong Answer

Solution code:
A,B=map(int,input().split())
a=A
b=A
c=0
while b<B:
    b+=(-1)+a
    c+=1
print(c+1)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
if b == 1:
    print(0)
else:
    ans = -(-b // a)
    print(ans)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
if b == 0:
    print(0)
else:
    ans = -(-b // a)
    print(ans)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
ans = -(-b // a)
print(ans)

Submission status: Wrong Answer

Solution code:
a = input().split(" ")
A = int(a[0])
B = int(a[1])

s = A
count = 1
while s< B:
  s += A -1
  count += 1
  
print(count)

Submission status: Wrong Answer

Solution code:
A, B = map(int,input().split())
num = A
ans = 1
while num < B:
    num += A-1
    ans += 1
print(ans)

Submission status: Wrong Answer

Solution code:
A, B = list(map(int, input().split()))
import math
ans = math.ceil(B / A)
print(ans)

Submission status: Wrong Answer

Solution code:
import math
a,b = map(int,input().split())
answer = 0
while b >0 :
    b-=a
    answer+=1
print(answer)

Submission status: Wrong Answer

Solution code:
import math
a,b = map(int,input().split())
for i in range(1,20):
    if a*i>= b:
        print(i)
        exit()

Submission status: Wrong Answer

Solution code:
a,b = [int(x) for x in input().split()]
sum_outlet = a
taps = 1
# A口ある電源タップを一個取り付けると、差込口はA-1個増える

while(sum_outlet < b):
      #print(sum_outlet,taps)
      taps += 1
      sum_outlet += a-1

print(taps)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
for i in range(21):
  if b<=1+(i-1)*a:
    print(i)
    break

Submission status: Wrong Answer

Solution code:
A, B = map(int, input().split())
for i in range(1, 20):
    if B <= A*i - (i - 1):
        print(i)
        break

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
if b==1:print(0)
elif a<b:
    if b%(a-1)<=1:print(b//(a-1))
    else:print(b//(a-1)+1)
elif a>=b:print(1)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())

cnt=0
aa=1
while b>aa:
    if cnt==0:
        cnt+=1
        aa+=a
    else:
        cnt+=1
        aa=(aa-1)+a

print(cnt)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())

cnt=0
aa=0
while b>aa:
    if cnt==0:
        cnt+=1
        aa+=a
    else:
        cnt+=1
        aa=(aa-1)+a

print(cnt)

Submission status: Wrong Answer

Solution code:
A,B=map(int,input().split())
if B>A:
  print(B//A+1)
elif B==0:
  print(0)
else:
  print(B//A)

Submission status: Wrong Answer

Solution code:
A, B = map(int,input().split())

if A >= B:
    print(1)
elif B <= 1:
    print(0)

elif (B-A) % (A-1) == 0:
    print((B-A) // (A-1) + 1)

else:
    print((B-A) // (A-1) + 2)

Submission status: Wrong Answer

Solution code:
A, B = map(int,input().split())

if A >= B:
    print(1)

elif (B-A) % (A-1) == 0:
    print((B-A) // (A-1) + 1)

else:
    print((B-A) // (A-1) + 2)

Submission status: Wrong Answer

Solution code:
a , b = map(int, input().split())
if b <=a:
    print(b // a )
elif b > a and (b - 1)%(a - 1)== 0:
    print((b - 1)// (a - 1))
elif b > a and (b - 1)%(a - 1)!= 0:
    print((b - 1)//(a - 1)+ 1)

Submission status: Wrong Answer

Solution code:
A,B=map(int,input().split())
if B%A==0:
    print(B//A)
else:
    print(B//A+1)

Submission status: Wrong Answer

Solution code:
a , b = map(int, input().split())
if b % a ==0 and b // a <= 1:
    print(b // a )
elif b > a and (b - 1)%(a - 1)== 0:
    print((b - 1)// (a - 1))
elif b > a and (b - 1)%(a - 1)!= 0:
    print((b - 1)//(a - 1)+ 1)
else:
    print(b // a + 1)

Submission status: Wrong Answer

Solution code:
a , b = map(int, input().split())
if b % a ==0 and b // a <= 1:
    print(b // a )
elif b % a ==0 and b // a > 1:
    print(b // a + 1)
else:
    print(b // a + 1)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
if b == 1:
    print("0")
elif 1 < b <= a:
    print("1")
elif b > a:
    if (b - a) / (a - 1) == (b - a) // (a - 1):
        print((b - a) // (a - 1) + 1)
else:
    print((b - a) // (a - 1) + 2)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
if b==1:
    print("0")
elif b>1 and b<=a:
    print("1")
elif b>a:
    if ((b-a)/(a-1)==(b-a)//(a-1)):
        print((b-a)//(a-1)+1)
else:
    print((b-a)//(a-1)+2)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
if a >= b:
  print(1)
elif int(b % (a - 1)) == 0:
  print(int(b / (a - 1)))
else:
  print(int(b / a + 1))

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
print(1) if a >= b else print(int(b / a + 1))

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
if a<b:print(b//a+1)
else:print(1)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
if a<b:print(b//a+1)
elif a==b:print(b//a)
else:print(1)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
if a<b:print(b//a+1)
elif a==b:print(b//a)
else:print(0)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
if a<b:print(b//a+1)
elif a==2 and b==1:print(0)
else:print(b//a)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
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)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
if a<b:print(b//a+1)
elif a==2 and b==1:print(1)
else:print(b//a)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
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)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
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)

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())
print(b//a + (1 if b % a != 0 else 0))

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
if a>=b:
  print(1)
elif a<b and b%a==0:
  print(b//a)
else:
  print(b//a+1)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
if a>=b:print(1)
else:print(b//a+1)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
if b>=a:
  if b%a>0:
    print(b//a+1)
  if b%a==0:
    print(b//a)
elif b==1:print(0)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
if b>a:
  if b%a>0:
    print(b//a+1)
  if b%a==0:
    print(b//a)
elif b==a:print(1)
elif b==1:print(0)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
if b>a:
  if b%a>0:
    print(b//a+1)
  if b%a==0:
    print(b//a)
else:print(1)

Submission status: Wrong Answer

Solution code:
a,b=map(int,input().split())
if b%a>0:print(b//a+1)
elif b<=a:print(1)
else:print(b//a)

Submission status: Wrong Answer

Solution code:
import math
A, B = map(int,input().split())
for i in range(30):
  if ((A-1)*i + A >= B):
    print(i+1)
    break

Submission status: Wrong Answer

Solution code:
import math
A, B = map(int,input().split())
for i in range(20):
  if ((A-1)*i + A >= B):
    print(i+1)
    break

Submission status: Wrong Answer

Solution code:
def powerSocket(a, b):
	if b % a == 0:
		return b // a
	else:
		return (b // a) + 1
a, b = map(int, input().split())
print(powerSocket(a, b))

Submission status: Wrong Answer

Solution code:
a, b = list(map(int, input().split()))
c = 0
sock = 0
while sock < b:
    sock += a if c == 0 else a - 1
    c += 1
print(c)

Submission status: Wrong Answer

Solution code:
a, b = list(map(int, input().split()))
print((b - 1) // a + 1)

Submission status: Wrong Answer

Solution code:
m, n = input().split()
m, n = int(m), int(n)

c = 1
a = m
while a<n:
  n-=(a-1)
  a=m
  c+=1

print(c)

Submission status: Wrong Answer

Solution code:
m, n = input().split()
m, n = int(m), int(n)

if n<=m: print(1)
else:
  r = n%(m-1)
  if r<=1:
    print(n//(m-1))
  else:
    print(n//(m-1) + 1)

Submission status: Wrong Answer

Solution code:
from math import ceil
A,B=list(map(int, input().split()))
print(ceil((B-1)//(A-1)))

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
c = 1
while a < b:
  a += a
  c += 1
print(c)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
c = 1
while a < b+1:
  a += a
  c += 1
print(c)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
c = 1
while True:
  if a >= b:
    break
  elif c == 1:
    a -= 1
    c += 1
    a += a+1
    continue
  c += 1
  a += a+1
print(c)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
c = 1
while True:
  if a >= b:
    break
  elif c == 1:
    a -= 1
    continue
  c += 1
  a += a+1
print(c)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
a -= 1
c = 1
while a < b:
  a += a+1
  c += 1
print(c)

Submission status: Wrong Answer

Solution code:
a, b = map(int, input().split())
a -= 1
c = 1
while a < b:
  a += a
  c += 1
print(c)