#include <stdio.h>

int main(){
   long long a,bb;
   int i;
   char b[5];

   scanf("%lld %s",&a,b);
   bb=0;
   for (i=0;b[i]!='\0';i++)
      if (b[i]!='.') bb=bb*10+b[i]-'0';
   printf("%lld\n",a*bb/100);
   return 0;
}