AB = list(input().split())



A = int(AB[0])

B = int(AB[1][:1] + AB[1][2:])

print((A * B // 100))
AB = list(input().split())

A = int(AB[0])

B = int(float(AB[1]) * 100 + 0.1)

print((A * B // 100))
AB = list(input().split())
A = int(AB[0])
B = int(AB[1][:1] + AB[1][2:])
print((A * B // 100))

AB = list(input().split())
A = int(AB[0])
B = int(float(AB[1]) * 100 + 0.1)
print((A * B // 100))

-B = int(AB[1][:1] + AB[1][2:]) +B = int(float(AB[1]) * 100 + 0.1)