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

print(((int(A)*round(B*100))//100))
A, B = list(map(str, input().split()))

B = ''.join(B.split('.'))

print((int(A)*int(B)//100))
A, B = list(map(float, input().split()))
print(((int(A) * round(B * 100)) // 100))

A, B = list(map(str, input().split()))
B = "".join(B.split("."))
print((int(A) * int(B) // 100))

-A, B = list(map(float, input().split())) -print(((int(A) * round(B * 100)) // 100)) +A, B = list(map(str, input().split())) +B = "".join(B.split(".")) +print((int(A) * int(B) // 100))