/* package codechef; // don't place package name! */

import java.util.*;
import java.lang.*;
import java.io.*;
import java.math.*;

/* Name of the class has to be "Main" only if the class is public. */
public class Main
{
	public static void main (String[] args) throws java.lang.Exception
	{
		// your code goes here
			PrintWriter out=new PrintWriter(System.out);
	FastScanner fs=new FastScanner();
		long a=fs.nextLong();
		double b=fs.nextDouble();
		
	 BigDecimal bg1 = BigDecimal.valueOf(a);
            BigDecimal bg2 = BigDecimal.valueOf(b);
            out.println(bg1.multiply(bg2).setScale(0, RoundingMode.DOWN));
		out.close();
		
	
	}
	static class FastScanner {
		BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
		StringTokenizer st=new StringTokenizer("");
		String next() {
			while (!st.hasMoreTokens())
				try {
					st=new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				}
			return st.nextToken();
		}
		
		int nextInt() {
			return Integer.parseInt(next());
		}
		int[] readArray(int n) {
			int[] a=new int[n];
			for (int i=0; i<n; i++) a[i]=nextInt();
			return a;
		}
		long nextLong() {
			return Long.parseLong(next());
		}
		double nextDouble(){
		    return Double.parseDouble(next());
		}
}
} import java.util.*; util.* java import java.lang.*; lang.* java import java.io.*; io.* java import java.math.*; math.* java public class Main
{
	public static void main (String[] args) throws java.lang.Exception
	{
		// your code goes here
			PrintWriter out=new PrintWriter(System.out);
	FastScanner fs=new FastScanner();
		long a=fs.nextLong();
		double b=fs.nextDouble();
		
	 BigDecimal bg1 = BigDecimal.valueOf(a);
            BigDecimal bg2 = BigDecimal.valueOf(b);
            out.println(bg1.multiply(bg2).setScale(0, RoundingMode.DOWN));
		out.close();
		
	
	}
	static class FastScanner {
		BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
		StringTokenizer st=new StringTokenizer("");
		String next() {
			while (!st.hasMoreTokens())
				try {
					st=new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				}
			return st.nextToken();
		}
		
		int nextInt() {
			return Integer.parseInt(next());
		}
		int[] readArray(int n) {
			int[] a=new int[n];
			for (int i=0; i<n; i++) a[i]=nextInt();
			return a;
		}
		long nextLong() {
			return Long.parseLong(next());
		}
		double nextDouble(){
		    return Double.parseDouble(next());
		}
}
} Main public static void main (String[] args) throws java.lang.Exception
	{
		// your code goes here
			PrintWriter out=new PrintWriter(System.out);
	FastScanner fs=new FastScanner();
		long a=fs.nextLong();
		double b=fs.nextDouble();
		
	 BigDecimal bg1 = BigDecimal.valueOf(a);
            BigDecimal bg2 = BigDecimal.valueOf(b);
            out.println(bg1.multiply(bg2).setScale(0, RoundingMode.DOWN));
		out.close();
		
	
	} main {
		// your code goes here
			PrintWriter out=new PrintWriter(System.out);
	FastScanner fs=new FastScanner();
		long a=fs.nextLong();
		double b=fs.nextDouble();
		
	 BigDecimal bg1 = BigDecimal.valueOf(a);
            BigDecimal bg2 = BigDecimal.valueOf(b);
            out.println(bg1.multiply(bg2).setScale(0, RoundingMode.DOWN));
		out.close();
		
	
	} PrintWriter out=new PrintWriter(System.out); out new PrintWriter(System.out) FastScanner fs=new FastScanner(); fs new FastScanner() long a=fs.nextLong(); a fs.nextLong() fs.nextLong fs double b=fs.nextDouble(); b fs.nextDouble() fs.nextDouble fs BigDecimal bg1 = BigDecimal.valueOf(a); bg1 BigDecimal.valueOf(a) BigDecimal.valueOf BigDecimal a BigDecimal bg2 = BigDecimal.valueOf(b); bg2 BigDecimal.valueOf(b) BigDecimal.valueOf BigDecimal b out.println(bg1.multiply(bg2).setScale(0, RoundingMode.DOWN)) out.println out bg1.multiply(bg2).setScale(0, RoundingMode.DOWN) bg1.multiply(bg2).setScale bg1.multiply(bg2) bg1.multiply bg1 bg2 0 RoundingMode.DOWN RoundingMode RoundingMode.DOWN out.close() out.close out String[] args args static class FastScanner {
		BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
		StringTokenizer st=new StringTokenizer("");
		String next() {
			while (!st.hasMoreTokens())
				try {
					st=new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				}
			return st.nextToken();
		}
		
		int nextInt() {
			return Integer.parseInt(next());
		}
		int[] readArray(int n) {
			int[] a=new int[n];
			for (int i=0; i<n; i++) a[i]=nextInt();
			return a;
		}
		long nextLong() {
			return Long.parseLong(next());
		}
		double nextDouble(){
		    return Double.parseDouble(next());
		}
} FastScanner BufferedReader br=new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) StringTokenizer st=new StringTokenizer(""); st new StringTokenizer("") String next() {
			while (!st.hasMoreTokens())
				try {
					st=new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				}
			return st.nextToken();
		} next {
			while (!st.hasMoreTokens())
				try {
					st=new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				}
			return st.nextToken();
		} while (!st.hasMoreTokens())
				try {
					st=new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				} !st.hasMoreTokens() st.hasMoreTokens() st.hasMoreTokens st try {
					st=new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				} catch (IOException e) {
					e.printStackTrace();
				} IOException e {
					e.printStackTrace();
				} e.printStackTrace() e.printStackTrace e {
					st=new StringTokenizer(br.readLine());
				} st=new StringTokenizer(br.readLine()) st new StringTokenizer(br.readLine()) return st.nextToken(); st.nextToken() st.nextToken st int nextInt() {
			return Integer.parseInt(next());
		} nextInt {
			return Integer.parseInt(next());
		} return Integer.parseInt(next()); Integer.parseInt(next()) Integer.parseInt Integer next() next int[] readArray(int n) {
			int[] a=new int[n];
			for (int i=0; i<n; i++) a[i]=nextInt();
			return a;
		} readArray {
			int[] a=new int[n];
			for (int i=0; i<n; i++) a[i]=nextInt();
			return a;
		} int[] a=new int[n]; a new int[n] n for (int i=0; i<n; i++) a[i]=nextInt(); int i=0; int i=0; i 0 i<n i n i++ i++ i a[i]=nextInt(); a[i]=nextInt() a[i] a i nextInt() nextInt return a; a int n n long nextLong() {
			return Long.parseLong(next());
		} nextLong {
			return Long.parseLong(next());
		} return Long.parseLong(next()); Long.parseLong(next()) Long.parseLong Long next() next double nextDouble(){
		    return Double.parseDouble(next());
		} nextDouble {
		    return Double.parseDouble(next());
		} return Double.parseDouble(next()); Double.parseDouble(next()) Double.parseDouble Double next() next public class Main
{
	public static void main (String[] args) throws java.lang.Exception
	{
		// your code goes here
			PrintWriter out=new PrintWriter(System.out);
	FastScanner fs=new FastScanner();
		long a=fs.nextLong();
		double b=fs.nextDouble();
		
	 BigDecimal bg1 = BigDecimal.valueOf(a);
            BigDecimal bg2 = BigDecimal.valueOf(b);
            out.println(bg1.multiply(bg2).setScale(0, RoundingMode.DOWN));
		out.close();
		
	
	}
	static class FastScanner {
		BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
		StringTokenizer st=new StringTokenizer("");
		String next() {
			while (!st.hasMoreTokens())
				try {
					st=new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				}
			return st.nextToken();
		}
		
		int nextInt() {
			return Integer.parseInt(next());
		}
		int[] readArray(int n) {
			int[] a=new int[n];
			for (int i=0; i<n; i++) a[i]=nextInt();
			return a;
		}
		long nextLong() {
			return Long.parseLong(next());
		}
		double nextDouble(){
		    return Double.parseDouble(next());
		}
}
} public class Main
{
	public static void main (String[] args) throws java.lang.Exception
	{
		// your code goes here
			PrintWriter out=new PrintWriter(System.out);
	FastScanner fs=new FastScanner();
		long a=fs.nextLong();
		double b=fs.nextDouble();
		
	 BigDecimal bg1 = BigDecimal.valueOf(a);
            BigDecimal bg2 = BigDecimal.valueOf(b);
            out.println(bg1.multiply(bg2).setScale(0, RoundingMode.DOWN));
		out.close();
		
	
	}
	static class FastScanner {
		BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
		StringTokenizer st=new StringTokenizer("");
		String next() {
			while (!st.hasMoreTokens())
				try {
					st=new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				}
			return st.nextToken();
		}
		
		int nextInt() {
			return Integer.parseInt(next());
		}
		int[] readArray(int n) {
			int[] a=new int[n];
			for (int i=0; i<n; i++) a[i]=nextInt();
			return a;
		}
		long nextLong() {
			return Long.parseLong(next());
		}
		double nextDouble(){
		    return Double.parseDouble(next());
		}
}
} Main
/* package codechef; // don't place package name! */

import java.util.*;
import java.lang.*;
import java.io.*;
import java.math.*;

/* Name of the class has to be "Main" only if the class is public. */
public class Main
{
	public static void main (String[] args) throws java.lang.Exception
	{
		// your code goes here
			PrintWriter out=new PrintWriter(System.out);
	FastScanner fs=new FastScanner();
		long a=fs.nextLong();
		double b=fs.nextDouble();
		
	 BigDecimal bg1 = BigDecimal.valueOf(a);
            BigDecimal bg2 = BigDecimal.valueOf(b);
            out.println(bg1.multiply(bg2).setScale(0, RoundingMode.DOWN));
		out.close();
		
	
	}
	static class FastScanner {
		BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
		StringTokenizer st=new StringTokenizer("");
		String next() {
			while (!st.hasMoreTokens())
				try {
					st=new StringTokenizer(br.readLine());
				} catch (IOException e) {
					e.printStackTrace();
				}
			return st.nextToken();
		}
		
		int nextInt() {
			return Integer.parseInt(next());
		}
		int[] readArray(int n) {
			int[] a=new int[n];
			for (int i=0; i<n; i++) a[i]=nextInt();
			return a;
		}
		long nextLong() {
			return Long.parseLong(next());
		}
		double nextDouble(){
		    return Double.parseDouble(next());
		}
}
}
