import kotlin.math.*
import java.io.BufferedReader
import java.io.InputStreamReader
import java.util.*


private var fs = BufferedReader(InputStreamReader(System.`in`))
private fun readLn() = fs.readLine()!! // string line
private fun readStrings() = readLn().split(" ") // list of strings
private fun readLong() = readLn().toLong()
private fun readLongs() = readStrings().map { it.toLong() } // list of ints
private fun readInt() = readLn().toInt() // single int
private fun readInts() = readStrings().map { it.toInt() } // list of ints

fun main() {
    solveAtc()
}
fun solveAtc() {
    var input = Scanner(System.`in`)
    input.useLocale(Locale.US)
    var a = input.nextLong()
    var b = input.next()
    var c = b.substringBeforeLast(".").toLong()
    var d = b.toString().substringAfterLast(".").toLong()
    println((d*a)/100L + c*a)
}
