Problem:

Division of Big Integers

  Given two integers $A$ and $B$, compute the quotient, $\frac{A}{B}$. Round down to the nearest decimal.

Input

  Two integers $A$ and $B$ separated by a space character are given in a line.

Output

  Print the quotient in a line.

Constraints

  
$-1 \times 10^{1000} \leq A, B \leq 10^{1000}$

  
$B \ne 0$

Sample Input 1

5 8

Sample Output 1

0

Sample Input 2

100 25

Sample Output 2

4

Sample Input 3

-1 3

Sample Output 3

0

Sample Input 4

12 -3

Sample Output 4

-4



Sample input:
5 8


Sample output:
0

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
from decimal import *
a,b = map(int, input().split())
print(int(Decimal(a)/Decimal(b)))

Submission status: Wrong Answer

Solution code:
import sys
a,b=map(int,sys.stdin.readline().split())
print(a//b)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
def div_round(x, y): return (x + (y // 2)) // y

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Accepted

Solution code:
import decimal
def main():
    a, b = map(int, input().split())
    decimal.getcontext().prec = len(str(a))
    print(int(decimal.Decimal(a)/decimal.Decimal(b)))


main()

Submission status: Accepted

Solution code:
import sys
a,b=map(int,sys.stdin.readline().split())
k=1
if a<0:
	k=-k
	a=-a
if b<0:
	k=-k
	b=-b
print(a//b*k)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

if a*b<0:
    print(-1*(abs(a)//abs(b)))
else:
    print(a//b)

Submission status: Accepted

Solution code:
a, b = [int(i) for i in input().split()]
if (a > 0 and b > 0) or (a < 0 and b < 0):
    print(abs(a) // abs(b))
else:
    print(abs(a) // abs(b) * -1)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

def round(a, b):
	if a * b < 0:
		return -(-a//b)
	else:
		return a//b

print(round(a, b))

Submission status: Accepted

Solution code:
m,n=map(int,input().split())
if m<0 and n>0:
    m*=-1
    print(-(m//n))
elif m>0 and n<0:
    n*=-1
    print(-(m//n))
else:
    print(m//n)

Submission status: Accepted

Solution code:
a, b=input().split(' ')
mi = 0
a=int(a)
b=int(b)
if a<0 and b<0:
    a*=-1
    b*=-1
if b<0:
    a*=-1
    b*=-1
if a<0:
    mi=1
    a*=-1
print(a//b*(-1)**mi)

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
def sign(x):
    return 1 if x >= 0 else -1
ans = abs(a) // abs(b) * sign(a) * sign(b)
print(ans)

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
print(a//b + bool(a*b < 0 and a % b))

Submission status: Accepted

Solution code:
def sign(x):
    return 1 if x>=0 else -1
a,b=map(int,input().split())
k=sign(a)*sign(b)
print(abs(a)//abs(b)*k)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a,s=map(int,input().split())
if a*s>=0:
    print(a//s)
else:
    print(-(abs(a)//abs(s)))

Submission status: Accepted

Solution code:
#標準入力
a,b = map(int,input().split())

#aの絶対値をbの絶対値で割った商をcに代入する
c = abs(a) // abs(b)

#a*bが負の数なら-c正の数ならcを出力する
print(-c if a * b < 0 else c)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys,bisect,math
A,B = map(int,sys.stdin.readline().split())
res = A//B
if res < 0 and A%B!=0:
  print(res+1)
  exit()
print(res)

Submission status: Accepted

Solution code:
A, B = map(int, input().split())
C = abs(A)//abs(B)
print(-C if A^B < 0 else C)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import math
n, m = map(int, input().split())
if n < 0 and m >= 0:
	print(abs(n) // abs(m) * -1)
elif n >= 0 and m < 0:
	print(abs(n) // abs(m) * -1)
else:
	print(n // m)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
if a < 0 and b >= 0 or a >= 0 and b < 0:
    print(0 - abs(a) // abs(b))
else:
    print(a//b)

Submission status: Accepted

Solution code:
a,b = map(int,input().split())
base = 10**1000
sign = (a<0) ^ (b<0)
print(((-1)**sign)*(abs(a)//abs(b)))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = input().split()
a = int(s[0])
b = int(s[1])
f = False
if a < 0 : 
    a = -a
    b = -b
if b < 0 :
    f = True
    b = -b
ans = a // b
if f : ans = -ans
print(ans)

Submission status: Accepted

Solution code:
A,B = map(int,input().split())
d = abs(A) // abs(B)
ans = -d if A * B < 0 else d
print(ans)

Submission status: Accepted

Solution code:
a,b = map(int,input().split())
res = abs(a) // abs(b)
if(a * b < 0):
    res *= -1
print(res)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

if(a*b<0):
  print(abs(a)//abs(b)*-1)
else:
  print(abs(a)//abs(b))

Submission status: Accepted

Solution code:
a, b = map(int, input().split())
s = 1
if a * b < 0:
    s = -1
print(abs(a) // abs(b) * s)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
(x,y)=map(int,input().split(' '))
po=1
if(x<0):x*=-1; po*=-1;
if(y<0):y*=-1; po*=-1;
print(po*(x//y));

Submission status: Accepted

Solution code:
a = map(long,raw_input().split(' '))
s = 1
if a[0] < 0:
    s = -s
    a[0] = -a[0]
if a[1] < 0:
    s = -s
    a[1] = -a[1]
print s * (a[0] // a[1])

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

if a*b > 0:
    print(c)
else:
    print(-c)

Submission status: Accepted

Solution code:
a,b=map(int, input().split())
c=abs(a)//abs(b)
print(c*(-1)**(a*b<0))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys

a,b=list(map(int,input().split()))
c=abs(a)//abs(b) 
print(c if a*b>=0 else -c)

Submission status: Accepted

Solution code:
if __name__ == "__main__":
    a, b = list(map(lambda x: int(x), input().split()))
    c = abs(a) // abs(b)
    if a * b < 0:
        print(-c)
    else:
        print(c)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a, b = [int(x) for x in input().split()]
c = abs(a) // abs(b)
print(-c if a ^ b < 0 else c)

Submission status: Accepted

Solution code:
#!usr/bin/env python3
from collections import defaultdict,deque
from heapq import heappush, heappop
import sys
import math
import bisect
import random
def LI(): return [int(x) for x in sys.stdin.readline().split()]
def I(): return int(sys.stdin.readline())
def LS():return [list(x) for x in sys.stdin.readline().split()]
def S(): return list(sys.stdin.readline())[:-1]
def IR(n):
    return [I() for i in range(n)]
def LIR(n):
    return [LI() for i in range(n)]
def SR(n):
    return [S() for i in range(n)]
def LSR(n):
    return [LS() for i in range(n)]

sys.setrecursionlimit(1000000)
mod = 1000000007
#1_A
"""
import math

n = int(input())
m = n
ans = []
i = 2
k = math.sqrt(n)
while i <= k:
    if n%i == 0:
        n = n//i
        ans.append(i)
        i -= 1
        if n == 1:
            break
    i += 1
if len(ans) == 0 or n != 1:
    ans.append(n)
print(m,end = ": ")
for i in range(len(ans)-1):
    print(ans[i], end = " ")
print(ans[-1])
"""

#1_B
"""
m,n = map(int, input().split())
b = bin(n)[2:]
num = [m]
for i in range(len(b)-1):
    num.append(num[-1]**2%1000000007)
ans = 1
for i in range(len(b)):
    ans *= num[i] if b[len(b)-1-i] == "1" else 1
    ans %= 1000000007
print(ans)
"""

#1_C
"""
import math

l = int(input())
a = list(map(int, input().split()))
dict = {}
for n in a:
    ans = []
    i = 2
    k = math.sqrt(n)
    dic = {}
    while i <= k:
        if n%i == 0:
            n = n//i
            ans.append(i)
            i -= 1
            if n == 1:
                break
        i += 1
    if len(ans) == 0 or n != 1:
        ans.append(n)
    for i in ans:
        if i in dic:
            dic[i] += 1
        else:
            dic[i] = 1
    for i in dic.keys():
        if i in dict:
            dict[i] = max(dict[i], dic[i])
        else:
            dict[i] = dic[i]
sum = 1
for x,y in dict.items():
    sum *= x**y
print(sum)
"""

#1_D
"""
import math

n = int(input())
m = n
ans = []
i = 2
k = math.sqrt(n)
dic = {}
while i <= k:
    if n%i == 0:
        n = n//i
        ans.append(i)
        i -= 1
        if n == 1:
            break
    i += 1
if len(ans) == 0 or n != 1:
    ans.append(n)
ans = list(set(ans))
sum = m
for i in ans:
    sum *= (1-1/i)
print(int(sum))
"""

#1_E
"""
def gcd(a,b):
    if a==0:
        return b
    return gcd(b%a,a)
a,b = LI()
g = gcd(a,b)
a//=g
b//=g
if b == 1:
    print(0,1)
    quit()
if b < 4:
    f = b-1
else:
    p = []
    x = 2
    m = b
    while x**2 <= b:
        if not m%x:
            p.append(x)
            while not m%x:
                m//=x
        x += 1
    if m != 1:p.append(m)
    f = b
    for i in p:
        f *= (1-1/i)
    f = int(f)
x_ = pow(a,f-1,b)
y_ = (1-a*x_)//b
ans = [x_,y_,abs(x_)+abs(y_)]
for i in range(-10000,10000):
    s = -b*i+x_
    t = a*i+y_
    m = abs(s)+abs(t)
    if m < ans[2]:
        ans = [s,t,m]
    elif m == ans[2] and s <= t:
        ans = [s,t,m]
print(ans[0],ans[1])
"""

#2
#2_A
"""
a,b = LI()
print(a+b)
"""

#2_B
"""
a,b = LI()
print(a-b)
"""

#2_C
"""
a,b = LI()
print(a*b)
"""

#2_D
a,b = LI()
if a*b < 0:
    print(-(-a//b))
else:
    print(a//b)

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
"""
Big Integers - Division of Big Integers
http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=NTL_2_D&lang=jp

"""
import sys


def main(args):
    A, B = map(int, input().split())
    sign = 1 if A*B >= 0 else -1
    print(abs(A) // abs(B) * sign)


if __name__ == '__main__':
    main(sys.argv[1:])

Submission status: Accepted

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

Submission status: Accepted

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

c = abs(A) // abs(B)

if A * B < 0:
    c = -c

print(c)

Submission status: Accepted

Solution code:
import sys,collections as cl,bisect as bs
sys.setrecursionlimit(100000)
Max = sys.maxsize
def l(): #intのlist
	return list(map(int,input().split()))
def m(): #複数文字
	return map(int,input().split())
def onem(): #Nとかの取得
	return int(input())
def s(x): #圧縮
	a = []
	aa = x[0]
	su = 1
	for i in range(len(x)-1):
		if aa == x[i+1]:
			a.append([aa,su])
			aa = x[i+1]
			su = 1
		else:
			su += 1
	a.append([aa,su])
	return a
def jo(x): #listをスペースごとに分ける
	return " ".join(map(str,x))
def max2(x): #他のときもどうように作成可能
	return max(map(max,x))

n,m= m()

if n*m > 0:
	print(n//m)
else:
	print(-(-n//m))

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
A, B = map(int, raw_input().split())
ans = A / B
if ans < 0 and A % B != 0:
    ans += 1
print ans

Submission status: Accepted

Solution code:
x,y = list(map(int, input().split()))
z = x*y
x = abs(x)
y = abs(y)
ans = x//y
if z<0:
  ans = ans * (-1)	
print(ans)

Submission status: Accepted

Solution code:
from decimal import *

a, b = input().rstrip().split(' ')

getcontext().prec = max(len(a), len(b)) + 1

ans = Decimal(a) / Decimal(b)
ans = ans.quantize(Decimal('1.'), rounding=ROUND_DOWN)
if ans == 0:
    print(0)
else:
    print(ans)

Submission status: Runtime Error

Solution code:
import math
import decimal
def main():
    a, b = map(int, input().split())
    decimal.getcontext().prec = int(math.log10(a)) + 1
    print(int(decimal.Decimal(a)/decimal.Decimal(b)))


main()

Submission status: Runtime Error

Solution code:
import math
import decimal
def main():
    a, b = map(int, input().split())
    decimal.getcontext().prec = int(math.log10(abs(a))) + 1
    print(int(decimal.Decimal(a)/decimal.Decimal(b)))


main()

Submission status: Runtime Error

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