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())

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

Submission status: Wrong Answer

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

if b > a:
	print((b-1)//(a-1))
else:
	print(1)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

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(" "))
k = 1
while ((a-1) * k + 1) < b:
    k +=1
print(k)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

answer = 0
while True:
    if answer*A < B:
        answer += 1
    else:
        break
print(answer)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
A, B = map(int, input().split())
i = 1
while A < B:
    i += 1
    if A*i > B:
        break

print(i)

Submission status: Wrong Answer

Solution code:
A, B = map(int, input().split())
i = 1
while A < B:
    i += 1
    A = A*i

print(i)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

result=a
count=1
while result < b:
    result += a-1
    count += 1

print(count)

Submission status: Wrong Answer

Solution code:
x = input().split()
A, B = [int(i) for i in x]
s = B % A
if s == 0:
  print(B//A)
else:
  print(B//A+1)

Submission status: Wrong Answer

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

print(count)

Submission status: Wrong Answer

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

print(count)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
import sys
a,b=map(int,input().split())
if a==b:
    print(1)
    sys.exit()
d=1
b-=a
while 1:
    
    b-=a-1
    d+=1
    if b<0:
        break
print(d)

Submission status: Wrong Answer

Solution code:
import sys
a,b=map(int,input().split())
if a==b:
    print(1)
    sys.exit()
d=1
b-=a
while 1:
    
    b-=a-1
    d+=1
    if b<=0:
        break
print(d)

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())
i=0
if b!=1:



    while True:
        if a + (a-1)*i < b:
            i+=1
        else :
            break

print(i)

Submission status: Wrong Answer

Solution code:
#139 b
a,b=map(int,input().split())
b-=a
ans=0
if b!=1:
    ans=1
    while b>0:
        b-=(a-1)
        ans+=1
print(ans)

Submission status: Wrong Answer

Solution code:
#139 b
a,b=map(int,input().split())
b-=a
ans=1
while b>0:
    b-=(a-1)
    ans+=1
print(ans)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
#!/usr/bin/env python3
import sys
import math

def solve(A: int, B: int):
    print(math.ceil(B / A))
    return


# Generated by 1.1.6 https://github.com/kyuridenamida/atcoder-tools  (tips: You use the default template now. You can remove this line by using your custom template)
def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    A = int(next(tokens))  # type: int
    B = int(next(tokens))  # type: int
    solve(A, B)

if __name__ == '__main__':
    main()

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

while True:
    if a*i < b:
        i += 1
    else:
        break

print(i)

Submission status: Wrong Answer

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

while True:
    if a*i >= b:
        break
    else:
        i += 1

print(i)

Submission status: Wrong Answer

Solution code:
lst = list(map(int,input().split(" ")))
n = 1
i = 1
while n < lst[1]:
  i += 1
  n = n-1+lst[0]
print("%d" % i)

Submission status: Wrong Answer

Solution code:
lst = list(map(int,input().split(" ")))
n = 1
while n < lst[1]:
  n = n-1+lst[0]
print("%d" % n)

Submission status: Wrong Answer

Solution code:
lst = list(map(int,input().split(" ")))
n = 1
while n < lst[1]:
  n = n-1+lst[0]
print(n)

Submission status: Wrong Answer

Solution code:
lst = list(map(int,input().split(" ")))
n = (lst[1]-1)/lst[0] +1
print("%d" % n )

Submission status: Wrong Answer

Solution code:
lst = list(map(int,input().split(" ")))
n = (lst[1]-1)/lst[0]
print("%d" % n )

Submission status: Wrong Answer

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

res = 0
for i in range(1,21):
    if (a-1) * (i-1) + a >= b:
        res = i
        break
    
print(res)

Submission status: Wrong Answer

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

ans=int((b-1)/(a-1))
print(ans)

Submission status: Wrong Answer

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

ans = B // (A-1)
if B % A != 0:
    ans += 1
print(ans)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

if A == B:
    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)
    exit()

sum = A
cnt = 1
while sum < B:
    sum += A - 1
    cnt += 1
print(cnt)

Submission status: Wrong Answer

Solution code:
a, b = [int(x) for x in input().split()]

cnt = 1
taps = a
while True:
    if taps >= b:
        break
    else:
        taps += a - 1
        cnt += 1

print(cnt)

Submission status: Wrong Answer

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

tmp = b // a
for i in range(tmp, 20 + 1):
    if a * i - tmp <= b:
        print(i)
        exit()

Submission status: Wrong Answer

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

tmp = b // a + 1
for i in range(tmp, 20 + 1):
    if a * i - tmp <= b:
        print(i)
        exit()

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

print(int(math.ceil(B/A)))

Submission status: Wrong Answer

Solution code:
A, B = map(int, input().split())
ans = 0
tap = 0
for i in range(10000):
    if i == 0:
        tap += A
        ans += 1
    if i >= 1:
        tap -= 1
        tap += A
        ans += 1
    if tap >= B:
        break
print(ans)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

if a >= b:
  print(1)
  exit()
  
n = 2
while n*a-(n-1) < b:
  n += 1
    
print(n)

Submission status: Wrong Answer

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

taps = 0
i = 0
while taps < b:
  i += 1
  taps = i*(a-1)+1

print(i)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
A, B = map(int, input().split())
cnt = 1
while A*cnt < B:
    cnt +=1
print(cnt)

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())
sumA = a
count  =1
t = True
while t:
    if a< b:
        count +=1
    elif a >= b:
        t = False
    a += a-1
print(count)

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())
sumA = a
count  =1
t = True
while t:
    if sumA<b:
        count +=1
    elif sumA>=b:
        t = False
    sumA += a-1
print(count)

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())
sumA = 0
count  =0
t = True
while t:
    if sumA<b:
        count +=1
    elif sumA>=b:
        t = False
    sumA += a
print(count)

Submission status: Wrong Answer

Solution code:
a,b = map(int,input().split())
sumA = 0
count  =0
t = True
while t:
    if sumA<=b:
        count +=1
    elif sumA>=b:
        t = False
    sumA += a
print(count)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

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())
count = 0
tap = 1
for i in range(30):
  tap += A-1
  count += 1
  if tap >= B:
    break
print(count)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

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

    count = 1
    ans = 0

    if a >= b:
        print(1)
        exit()

    while(count < b):
        count -= 1
        count += a
        ans += 1

    print(ans)


if __name__ == '__main__':
    main()

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

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

    count = 1

    while(1):
        x = a * count - (count-1)
        if x >= b:
            print(count)
            break
        count += 1

if __name__ == '__main__':
    main()

Submission status: Wrong Answer

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

    count = 1

    while(1):
        x = a * count - (count-1)
        if x >= b:
            break
        count += 1

if __name__ == '__main__':
    main()

Submission status: Wrong Answer

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

    count = 0

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

if __name__ == '__main__':
    main()

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

tap = 1
n = a
while n < b:
    n -= 1
    n += a
    tap+=1

print(tap)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

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

if A >= B:
    print(1)
else:
    elc = 0
    while (A + (A - 1)*elc) <= B:
        elc += 1

    print(elc + 1)

Submission status: Wrong Answer

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

if A >= B:
    print(1)
else:
    elc = 0
    while (A + (A - 1)*elc) < B:
        elc += 1

    print(elc + 1)

Submission status: Wrong Answer

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

ans = 0
taps = 1
while taps < B:
    print(taps)
    taps += A - 1
    ans += 1

print(ans)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

count=0
tmp=0

for i in range(1,21):
    if (a-1)*i+1 >= b:
        print(i)
        break

Submission status: Wrong Answer

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

if a==b:
    print(1)
else:
    print((b-1)//(a-1)+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(' '))

print(-(-B//A))

Submission status: Wrong Answer

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

if __name__ == '__main__':
    main()

Submission status: Wrong Answer

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

if __name__ == '__main__':
    main()

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

if __name__ == '__main__':
    main()

Submission status: Wrong Answer

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

if __name__ == '__main__':
    main()

Submission status: Wrong Answer

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

left = max(b - a, 0)
if left == 0:
    print(1)
    exit(0)

if left % (a - 1) == 0:
    print(left // (a - 1) + 1)
else:
    print(left // (a - 1) + 2)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
A, B = map(int, input().split())
num = 0
c = 1
tf = True
while tf:
    if B == 1:
        print("0")
        tf = False
    elif c < B:
      c += A - 1
      num += 1
    else:
        tf = False
print(num)

Submission status: Wrong Answer

Solution code:
A, B = map(int, input().split())
num = 0
c = 1
tf = True
while tf:
    if B == 1:
        print(0)
        tf = False
    elif c < B:
      c += A - 1
      num += 1
    else:
        tf = False
print(num)

Submission status: Wrong Answer

Solution code:
A, B = map(int, input().split())
c = 1
tf = True
while tf:
    if (A*c-1) < B:
      c += 1
    else:
        tf = False
print(c)

Submission status: Wrong Answer

Solution code:
A, B = map(int, input().split())
c = 1
tf = True
while tf:
    if A*c < B:
      c += 1
    else:
        tf = False
print(c)

Submission status: Wrong Answer

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

    if B%A == 0:
        print(B//A)
    else:
        print((B//A) + 1)



if __name__ == '__main__':
    main()

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

ans = 0
output = 0

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

Submission status: Wrong Answer

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

ans = 0
output = 0

if A >= B:
  print(1)
else:
  while (A-1)*ans < B-A:
    ans += 1
    
  print(ans+1)

Submission status: Wrong Answer

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

ans = 0
output = 0

if A >= B:
  print(1)
else:
  while (A-1)*ans < B-4:
    ans += 1
    
  print(ans+1)

Submission status: Wrong Answer

Solution code:
import sys
import math
import heapq
sys.setrecursionlimit(10**7)
INTMAX = 9223372036854775807
INTMIN = -9223372036854775808
DVSR = 1000000007
def POW(x, y): return pow(x, y, DVSR)
def INV(x, m=DVSR): return pow(x, m - 2, m)
def DIV(x, y, m=DVSR): return (x * INV(y, m)) % m
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())
def FLIST(n):
    res = [1]
    for i in range(1, n+1): res.append(res[i-1]*i%DVSR)
    return res
def gcd(x, y):
    if x < y: x, y = y, x
    div = x % y
    while div != 0:
        x, y = y, div
        div = x % y
    return y

A,B=LI()

print(B//A + (1 if B%A else 0))

Submission status: Wrong Answer

Solution code:
a, b = input().split(' ')
c = int(a)
d = int(b)

if d//c==1 and d%c==0:
  print(str(1))
else:
  print(str(d//c+1))

Submission status: Wrong Answer

Solution code:
a, b = input().split(' ')
c = int(a)
d = int(b)

if d%c == 0:
  print(str(d//c))
else:
  print(str(d//c+1))

Submission status: Wrong Answer

Solution code:
# -*- coding: utf-8 -*-
a, b = [int(i) for i in input().split()]

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

Submission status: Wrong Answer

Solution code:
# -*- coding: utf-8 -*-
a, b = [int(i) for i in input().split()]

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

Submission status: Wrong Answer

Solution code:
# -*- coding: utf-8 -*-
a, b = [int(i) for i in input().split()]

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
a, b = [int(_) for _ in input().split()]
n = b // a
n += b > n*a
print(0 if b == 1 else n)

Submission status: Wrong Answer

Solution code:
a, b = [int(_) for _ in input().split()]
print(b // a + (b % a > 0))

Submission status: Wrong Answer

Solution code:
a = list(map(int,input().split()))
i = 0

while True:
    if a[1] == 1:
        print(0)
        break
    
    if a[0] + a[0]*i >= a[1]:
        print(i+1)
        break
    else:
        i += 1

Submission status: Wrong Answer

Solution code:
a = list(map(int,input().split()))
i = 1

while True:
    if a[1] == 1:
        print(0)
        break
    
    if a[0]*i >= a[1]:
        print(i)
        break
    else:
        i += 1

Submission status: Wrong Answer

Solution code:
a = list(map(int,input().split()))
i = 1

while True:
    if a[0] >= a[1]:
        print(0)
        break
    
    if a[0]*i >= a[1]:
        print(i)
        break
    else:
        i += 1

Submission status: Wrong Answer

Solution code:
a = list(map(int,input().split()))
i = 1

while True:
    if a[0]*i >= a[1]:
        print(i)
        break
    else:
        i += 1

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

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())

tap = A
ans = 1

while True:
    if tap<B:
        tap += (A-1)
        ans += 1
    else:
        break

print(ans)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
import math
A = list(map(int,input().split(" ")))
if A[1] / A[0] > 1:
    A[1] -= A[0]
    print(math.ceil(A[1] / (A[0] - 1))+ 1)
else:
    print("1")

Submission status: Wrong Answer

Solution code:
import math
A = list(map(int,input().split(" ")))
if A[1] / A[0] > 1:
    A[1] -= A[0]
    print(math.ceil(A[1] / A[0])+ 1)
else:
    print("1")

Submission status: Wrong Answer

Solution code:
import math
A = list(map(int,input().split(" ")))
if A[1] / A[0] > 1:
    A[1] -= A[0]
    print(math.ceil(A[1]) + 1)
else:
    print("1")

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
import math
A = list(map(int,input().split(" ")))
B = math.ceil(A[1] / A[0])
print(B)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
# Power Socket

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

# solve
if B == 1:
    res = 1
else:
    res = 1
    tap = A
    while tap < B:
        tap += A - 1
        res += 1

# output
print(res)

Submission status: Wrong Answer

Solution code:
import math
A = list(map(int,input().split(" ")))
B = math.floor(A[1] / A[0]) + 1
print(B)

Submission status: Wrong Answer

Solution code:
import math
A = list(map(int,input().split(" ")))
B = math.ceil(A[1] / A[0]) + 1
print(B)

Submission status: Wrong Answer

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

if a >= b:
  print(1)
else:
  c = 1
  count=0
  while b > c:
    c += a-1
    
    count += 1
  print(count)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

if a >= b:
  print(1)
else:
  count=1
  b -= a
  while b >= 0:
    b -= (a-1)
    
    count += 1
  print(count)

Submission status: Wrong Answer

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

for i in range(20):
    if a * i >= b:
        print(i)
        break

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
A,B=map(int, input().split())
ans=0
while B > 0:
  B -= A
  ans+=1
  if B != 0:
    B += 1
if B == 1:
  print("0")
else:
  print(ans)

Submission status: Wrong Answer

Solution code:
A,B=map(int, input().split())
ans=0
while B > 0:
  B -= A
  ans+=1
  if B != 0:
    B += 1
print(ans)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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