import Foundation

let words = readLine()!.components(separatedBy: " ")
let a = Int(words[0])!
let b = words[1].components(separatedBy: ".").map(Int.init)

let up = a * b[0]!
let bottom = a * b[1]! / 100
print(up + bottom)

