

import java.io.IOException;
import java.math.BigDecimal;
import java.math.BigInteger;
import java.util.Map;
import java.util.Scanner;

public class Main {
    static Map<BigInteger, Integer> memo;

    public static void main(String[] args) throws IOException {
        Scanner sc = new Scanner(System.in);

        BigInteger a = sc.nextBigInteger();
        BigDecimal b =sc.nextBigDecimal();

        System.out.println(b.multiply(new BigDecimal(a)).toBigInteger());

    }


    static int lowerBound(int[] arr, int element) {

        int low = 0, high = arr.length - 1, ans = 0;
        while (low <= high) {
            int mid = low + (high - low) / 2;
            if (arr[mid] <= element) {
                low = mid + 1;
                ans = mid;
            } else
                high = mid - 1;

        }

        return high;
    }

    static boolean isPalindrome(String word) {
        int i = 0, j = word.length() - 1;

        while (i <= j) {
            if (word.charAt(i++) != word.charAt(j--))
                return false;
        }

        return true;
    }

    static String longestPalindrome(String[] words, String word, int i) {
        if (i >= words.length) {
            if (isPalindrome(word))
                return word;

            return "";
        }

        if (word.length() > 0 && isPalindrome(word))
            return word;
        String left = longestPalindrome(words, word + words[i], i + 1);
        String right = longestPalindrome(words, word, i + 1);

        if (left.length() > 0)
            return left;
        return right;
    }


    static int solve(int[] arr, int i, int j, int k) {
        if (i == j && arr[i] <= k)
            return 1;

        int left = 0, right = 0;
        if (arr[i] <= k)
            left = solve(arr, i + 1, j, k) + 1;

        else if (arr[j] <= k)
            right = solve(arr, i, j - 1, k) + 1;

        return left + right;
    }

    static int minMove(BigInteger bg, int count) {
        if (bg.equals(BigInteger.ONE))
            return count;

        int first = Integer.MAX_VALUE, sec = Integer.MAX_VALUE, last = Integer.MAX_VALUE;
        if (bg.mod(BigInteger.valueOf(2)).compareTo(BigInteger.ZERO) == 0)
            first = minMove(bg.divide(BigInteger.valueOf(2)), count + 1);

        else if (bg.mod(BigInteger.valueOf(3)).compareTo(BigInteger.ZERO) == 0)
            sec = minMove(bg.multiply(BigInteger.valueOf(2)).divide(BigInteger.valueOf(3)), count + 1);

        else if (bg.mod(BigInteger.valueOf(5)).compareTo(BigInteger.ZERO) == 0)
            last = minMove(bg.multiply(BigInteger.valueOf(4)).divide(BigInteger.valueOf(5)), count + 1);

        if (memo.containsKey(bg))
            return memo.get(bg);

        memo.put(bg, Math.min(first, Math.min(sec, last)));

        return Math.min(first, Math.min(sec, last));
    }
} import java.io.IOException; IOException java.io import java.math.BigDecimal; BigDecimal java.math import java.math.BigInteger; BigInteger java.math import java.util.Map; Map java.util import java.util.Scanner; Scanner java.util public class Main {
    static Map<BigInteger, Integer> memo;

    public static void main(String[] args) throws IOException {
        Scanner sc = new Scanner(System.in);

        BigInteger a = sc.nextBigInteger();
        BigDecimal b =sc.nextBigDecimal();

        System.out.println(b.multiply(new BigDecimal(a)).toBigInteger());

    }


    static int lowerBound(int[] arr, int element) {

        int low = 0, high = arr.length - 1, ans = 0;
        while (low <= high) {
            int mid = low + (high - low) / 2;
            if (arr[mid] <= element) {
                low = mid + 1;
                ans = mid;
            } else
                high = mid - 1;

        }

        return high;
    }

    static boolean isPalindrome(String word) {
        int i = 0, j = word.length() - 1;

        while (i <= j) {
            if (word.charAt(i++) != word.charAt(j--))
                return false;
        }

        return true;
    }

    static String longestPalindrome(String[] words, String word, int i) {
        if (i >= words.length) {
            if (isPalindrome(word))
                return word;

            return "";
        }

        if (word.length() > 0 && isPalindrome(word))
            return word;
        String left = longestPalindrome(words, word + words[i], i + 1);
        String right = longestPalindrome(words, word, i + 1);

        if (left.length() > 0)
            return left;
        return right;
    }


    static int solve(int[] arr, int i, int j, int k) {
        if (i == j && arr[i] <= k)
            return 1;

        int left = 0, right = 0;
        if (arr[i] <= k)
            left = solve(arr, i + 1, j, k) + 1;

        else if (arr[j] <= k)
            right = solve(arr, i, j - 1, k) + 1;

        return left + right;
    }

    static int minMove(BigInteger bg, int count) {
        if (bg.equals(BigInteger.ONE))
            return count;

        int first = Integer.MAX_VALUE, sec = Integer.MAX_VALUE, last = Integer.MAX_VALUE;
        if (bg.mod(BigInteger.valueOf(2)).compareTo(BigInteger.ZERO) == 0)
            first = minMove(bg.divide(BigInteger.valueOf(2)), count + 1);

        else if (bg.mod(BigInteger.valueOf(3)).compareTo(BigInteger.ZERO) == 0)
            sec = minMove(bg.multiply(BigInteger.valueOf(2)).divide(BigInteger.valueOf(3)), count + 1);

        else if (bg.mod(BigInteger.valueOf(5)).compareTo(BigInteger.ZERO) == 0)
            last = minMove(bg.multiply(BigInteger.valueOf(4)).divide(BigInteger.valueOf(5)), count + 1);

        if (memo.containsKey(bg))
            return memo.get(bg);

        memo.put(bg, Math.min(first, Math.min(sec, last)));

        return Math.min(first, Math.min(sec, last));
    }
} Main static Map<BigInteger, Integer> memo; memo public static void main(String[] args) throws IOException {
        Scanner sc = new Scanner(System.in);

        BigInteger a = sc.nextBigInteger();
        BigDecimal b =sc.nextBigDecimal();

        System.out.println(b.multiply(new BigDecimal(a)).toBigInteger());

    } main {
        Scanner sc = new Scanner(System.in);

        BigInteger a = sc.nextBigInteger();
        BigDecimal b =sc.nextBigDecimal();

        System.out.println(b.multiply(new BigDecimal(a)).toBigInteger());

    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) BigInteger a = sc.nextBigInteger(); a sc.nextBigInteger() sc.nextBigInteger sc BigDecimal b =sc.nextBigDecimal(); b sc.nextBigDecimal() sc.nextBigDecimal sc System.out.println(b.multiply(new BigDecimal(a)).toBigInteger()) System.out.println System.out System System.out b.multiply(new BigDecimal(a)).toBigInteger() b.multiply(new BigDecimal(a)).toBigInteger b.multiply(new BigDecimal(a)) b.multiply b new BigDecimal(a) String[] args args static int lowerBound(int[] arr, int element) {

        int low = 0, high = arr.length - 1, ans = 0;
        while (low <= high) {
            int mid = low + (high - low) / 2;
            if (arr[mid] <= element) {
                low = mid + 1;
                ans = mid;
            } else
                high = mid - 1;

        }

        return high;
    } lowerBound {

        int low = 0, high = arr.length - 1, ans = 0;
        while (low <= high) {
            int mid = low + (high - low) / 2;
            if (arr[mid] <= element) {
                low = mid + 1;
                ans = mid;
            } else
                high = mid - 1;

        }

        return high;
    } int low = 0 low 0 high = arr.length - 1 high arr.length - 1 arr.length arr arr.length 1 ans = 0; ans 0 while (low <= high) {
            int mid = low + (high - low) / 2;
            if (arr[mid] <= element) {
                low = mid + 1;
                ans = mid;
            } else
                high = mid - 1;

        } low <= high low high {
            int mid = low + (high - low) / 2;
            if (arr[mid] <= element) {
                low = mid + 1;
                ans = mid;
            } else
                high = mid - 1;

        } int mid = low + (high - low) / 2; mid low + (high - low) / 2 low (high - low) / 2 (high - low) high low 2 if (arr[mid] <= element) {
                low = mid + 1;
                ans = mid;
            } else
                high = mid - 1; arr[mid] <= element arr[mid] arr mid element {
                low = mid + 1;
                ans = mid;
            } low = mid + 1 low mid + 1 mid 1 ans = mid ans mid high = mid - 1 high mid - 1 mid 1 return high; high int[] arr arr int element element static boolean isPalindrome(String word) {
        int i = 0, j = word.length() - 1;

        while (i <= j) {
            if (word.charAt(i++) != word.charAt(j--))
                return false;
        }

        return true;
    } isPalindrome {
        int i = 0, j = word.length() - 1;

        while (i <= j) {
            if (word.charAt(i++) != word.charAt(j--))
                return false;
        }

        return true;
    } int i = 0 i 0 j = word.length() - 1; j word.length() - 1 word.length() word.length word 1 while (i <= j) {
            if (word.charAt(i++) != word.charAt(j--))
                return false;
        } i <= j i j {
            if (word.charAt(i++) != word.charAt(j--))
                return false;
        } if (word.charAt(i++) != word.charAt(j--))
                return false; word.charAt(i++) != word.charAt(j--) word.charAt(i++) word.charAt word i++ i word.charAt(j--) word.charAt word j-- j return false; false return true; true String word word static String longestPalindrome(String[] words, String word, int i) {
        if (i >= words.length) {
            if (isPalindrome(word))
                return word;

            return "";
        }

        if (word.length() > 0 && isPalindrome(word))
            return word;
        String left = longestPalindrome(words, word + words[i], i + 1);
        String right = longestPalindrome(words, word, i + 1);

        if (left.length() > 0)
            return left;
        return right;
    } longestPalindrome {
        if (i >= words.length) {
            if (isPalindrome(word))
                return word;

            return "";
        }

        if (word.length() > 0 && isPalindrome(word))
            return word;
        String left = longestPalindrome(words, word + words[i], i + 1);
        String right = longestPalindrome(words, word, i + 1);

        if (left.length() > 0)
            return left;
        return right;
    } if (i >= words.length) {
            if (isPalindrome(word))
                return word;

            return "";
        } i >= words.length i words.length words words.length {
            if (isPalindrome(word))
                return word;

            return "";
        } if (isPalindrome(word))
                return word; isPalindrome(word) isPalindrome word return word; word return ""; "" if (word.length() > 0 && isPalindrome(word))
            return word; word.length() > 0 && isPalindrome(word) word.length() > 0 word.length() word.length word 0 isPalindrome(word) isPalindrome word return word; word String left = longestPalindrome(words, word + words[i], i + 1); left longestPalindrome(words, word + words[i], i + 1) longestPalindrome words word + words[i] word words[i] words i i + 1 i 1 String right = longestPalindrome(words, word, i + 1); right longestPalindrome(words, word, i + 1) longestPalindrome words word i + 1 i 1 if (left.length() > 0)
            return left; left.length() > 0 left.length() left.length left 0 return left; left return right; right String[] words words String word word int i i static int solve(int[] arr, int i, int j, int k) {
        if (i == j && arr[i] <= k)
            return 1;

        int left = 0, right = 0;
        if (arr[i] <= k)
            left = solve(arr, i + 1, j, k) + 1;

        else if (arr[j] <= k)
            right = solve(arr, i, j - 1, k) + 1;

        return left + right;
    } solve {
        if (i == j && arr[i] <= k)
            return 1;

        int left = 0, right = 0;
        if (arr[i] <= k)
            left = solve(arr, i + 1, j, k) + 1;

        else if (arr[j] <= k)
            right = solve(arr, i, j - 1, k) + 1;

        return left + right;
    } if (i == j && arr[i] <= k)
            return 1; i == j && arr[i] <= k i == j i j arr[i] <= k arr[i] arr i k return 1; 1 int left = 0 left 0 right = 0; right 0 if (arr[i] <= k)
            left = solve(arr, i + 1, j, k) + 1;

        else if (arr[j] <= k)
            right = solve(arr, i, j - 1, k) + 1; arr[i] <= k arr[i] arr i k left = solve(arr, i + 1, j, k) + 1 left solve(arr, i + 1, j, k) + 1 solve(arr, i + 1, j, k) solve arr i + 1 i 1 j k 1 if (arr[j] <= k)
            right = solve(arr, i, j - 1, k) + 1; arr[j] <= k arr[j] arr j k right = solve(arr, i, j - 1, k) + 1 right solve(arr, i, j - 1, k) + 1 solve(arr, i, j - 1, k) solve arr i j - 1 j 1 k 1 return left + right; left + right left right int[] arr arr int i i int j j int k k static int minMove(BigInteger bg, int count) {
        if (bg.equals(BigInteger.ONE))
            return count;

        int first = Integer.MAX_VALUE, sec = Integer.MAX_VALUE, last = Integer.MAX_VALUE;
        if (bg.mod(BigInteger.valueOf(2)).compareTo(BigInteger.ZERO) == 0)
            first = minMove(bg.divide(BigInteger.valueOf(2)), count + 1);

        else if (bg.mod(BigInteger.valueOf(3)).compareTo(BigInteger.ZERO) == 0)
            sec = minMove(bg.multiply(BigInteger.valueOf(2)).divide(BigInteger.valueOf(3)), count + 1);

        else if (bg.mod(BigInteger.valueOf(5)).compareTo(BigInteger.ZERO) == 0)
            last = minMove(bg.multiply(BigInteger.valueOf(4)).divide(BigInteger.valueOf(5)), count + 1);

        if (memo.containsKey(bg))
            return memo.get(bg);

        memo.put(bg, Math.min(first, Math.min(sec, last)));

        return Math.min(first, Math.min(sec, last));
    } minMove {
        if (bg.equals(BigInteger.ONE))
            return count;

        int first = Integer.MAX_VALUE, sec = Integer.MAX_VALUE, last = Integer.MAX_VALUE;
        if (bg.mod(BigInteger.valueOf(2)).compareTo(BigInteger.ZERO) == 0)
            first = minMove(bg.divide(BigInteger.valueOf(2)), count + 1);

        else if (bg.mod(BigInteger.valueOf(3)).compareTo(BigInteger.ZERO) == 0)
            sec = minMove(bg.multiply(BigInteger.valueOf(2)).divide(BigInteger.valueOf(3)), count + 1);

        else if (bg.mod(BigInteger.valueOf(5)).compareTo(BigInteger.ZERO) == 0)
            last = minMove(bg.multiply(BigInteger.valueOf(4)).divide(BigInteger.valueOf(5)), count + 1);

        if (memo.containsKey(bg))
            return memo.get(bg);

        memo.put(bg, Math.min(first, Math.min(sec, last)));

        return Math.min(first, Math.min(sec, last));
    } if (bg.equals(BigInteger.ONE))
            return count; bg.equals(BigInteger.ONE) bg.equals bg BigInteger.ONE BigInteger BigInteger.ONE return count; count int first = Integer.MAX_VALUE first Integer.MAX_VALUE Integer Integer.MAX_VALUE sec = Integer.MAX_VALUE sec Integer.MAX_VALUE Integer Integer.MAX_VALUE last = Integer.MAX_VALUE; last Integer.MAX_VALUE Integer Integer.MAX_VALUE if (bg.mod(BigInteger.valueOf(2)).compareTo(BigInteger.ZERO) == 0)
            first = minMove(bg.divide(BigInteger.valueOf(2)), count + 1);

        else if (bg.mod(BigInteger.valueOf(3)).compareTo(BigInteger.ZERO) == 0)
            sec = minMove(bg.multiply(BigInteger.valueOf(2)).divide(BigInteger.valueOf(3)), count + 1);

        else if (bg.mod(BigInteger.valueOf(5)).compareTo(BigInteger.ZERO) == 0)
            last = minMove(bg.multiply(BigInteger.valueOf(4)).divide(BigInteger.valueOf(5)), count + 1); bg.mod(BigInteger.valueOf(2)).compareTo(BigInteger.ZERO) == 0 bg.mod(BigInteger.valueOf(2)).compareTo(BigInteger.ZERO) bg.mod(BigInteger.valueOf(2)).compareTo bg.mod(BigInteger.valueOf(2)) bg.mod bg BigInteger.valueOf(2) BigInteger.valueOf BigInteger 2 BigInteger.ZERO BigInteger BigInteger.ZERO 0 first = minMove(bg.divide(BigInteger.valueOf(2)), count + 1) first minMove(bg.divide(BigInteger.valueOf(2)), count + 1) minMove bg.divide(BigInteger.valueOf(2)) bg.divide bg BigInteger.valueOf(2) BigInteger.valueOf BigInteger 2 count + 1 count 1 if (bg.mod(BigInteger.valueOf(3)).compareTo(BigInteger.ZERO) == 0)
            sec = minMove(bg.multiply(BigInteger.valueOf(2)).divide(BigInteger.valueOf(3)), count + 1);

        else if (bg.mod(BigInteger.valueOf(5)).compareTo(BigInteger.ZERO) == 0)
            last = minMove(bg.multiply(BigInteger.valueOf(4)).divide(BigInteger.valueOf(5)), count + 1); bg.mod(BigInteger.valueOf(3)).compareTo(BigInteger.ZERO) == 0 bg.mod(BigInteger.valueOf(3)).compareTo(BigInteger.ZERO) bg.mod(BigInteger.valueOf(3)).compareTo bg.mod(BigInteger.valueOf(3)) bg.mod bg BigInteger.valueOf(3) BigInteger.valueOf BigInteger 3 BigInteger.ZERO BigInteger BigInteger.ZERO 0 sec = minMove(bg.multiply(BigInteger.valueOf(2)).divide(BigInteger.valueOf(3)), count + 1) sec minMove(bg.multiply(BigInteger.valueOf(2)).divide(BigInteger.valueOf(3)), count + 1) minMove bg.multiply(BigInteger.valueOf(2)).divide(BigInteger.valueOf(3)) bg.multiply(BigInteger.valueOf(2)).divide bg.multiply(BigInteger.valueOf(2)) bg.multiply bg BigInteger.valueOf(2) BigInteger.valueOf BigInteger 2 BigInteger.valueOf(3) BigInteger.valueOf BigInteger 3 count + 1 count 1 if (bg.mod(BigInteger.valueOf(5)).compareTo(BigInteger.ZERO) == 0)
            last = minMove(bg.multiply(BigInteger.valueOf(4)).divide(BigInteger.valueOf(5)), count + 1); bg.mod(BigInteger.valueOf(5)).compareTo(BigInteger.ZERO) == 0 bg.mod(BigInteger.valueOf(5)).compareTo(BigInteger.ZERO) bg.mod(BigInteger.valueOf(5)).compareTo bg.mod(BigInteger.valueOf(5)) bg.mod bg BigInteger.valueOf(5) BigInteger.valueOf BigInteger 5 BigInteger.ZERO BigInteger BigInteger.ZERO 0 last = minMove(bg.multiply(BigInteger.valueOf(4)).divide(BigInteger.valueOf(5)), count + 1) last minMove(bg.multiply(BigInteger.valueOf(4)).divide(BigInteger.valueOf(5)), count + 1) minMove bg.multiply(BigInteger.valueOf(4)).divide(BigInteger.valueOf(5)) bg.multiply(BigInteger.valueOf(4)).divide bg.multiply(BigInteger.valueOf(4)) bg.multiply bg BigInteger.valueOf(4) BigInteger.valueOf BigInteger 4 BigInteger.valueOf(5) BigInteger.valueOf BigInteger 5 count + 1 count 1 if (memo.containsKey(bg))
            return memo.get(bg); memo.containsKey(bg) memo.containsKey memo bg return memo.get(bg); memo.get(bg) memo.get memo bg memo.put(bg, Math.min(first, Math.min(sec, last))) memo.put memo bg Math.min(first, Math.min(sec, last)) Math.min Math first Math.min(sec, last) Math.min Math sec last return Math.min(first, Math.min(sec, last)); Math.min(first, Math.min(sec, last)) Math.min Math first Math.min(sec, last) Math.min Math sec last BigInteger bg bg int count count public class Main {
    static Map<BigInteger, Integer> memo;

    public static void main(String[] args) throws IOException {
        Scanner sc = new Scanner(System.in);

        BigInteger a = sc.nextBigInteger();
        BigDecimal b =sc.nextBigDecimal();

        System.out.println(b.multiply(new BigDecimal(a)).toBigInteger());

    }


    static int lowerBound(int[] arr, int element) {

        int low = 0, high = arr.length - 1, ans = 0;
        while (low <= high) {
            int mid = low + (high - low) / 2;
            if (arr[mid] <= element) {
                low = mid + 1;
                ans = mid;
            } else
                high = mid - 1;

        }

        return high;
    }

    static boolean isPalindrome(String word) {
        int i = 0, j = word.length() - 1;

        while (i <= j) {
            if (word.charAt(i++) != word.charAt(j--))
                return false;
        }

        return true;
    }

    static String longestPalindrome(String[] words, String word, int i) {
        if (i >= words.length) {
            if (isPalindrome(word))
                return word;

            return "";
        }

        if (word.length() > 0 && isPalindrome(word))
            return word;
        String left = longestPalindrome(words, word + words[i], i + 1);
        String right = longestPalindrome(words, word, i + 1);

        if (left.length() > 0)
            return left;
        return right;
    }


    static int solve(int[] arr, int i, int j, int k) {
        if (i == j && arr[i] <= k)
            return 1;

        int left = 0, right = 0;
        if (arr[i] <= k)
            left = solve(arr, i + 1, j, k) + 1;

        else if (arr[j] <= k)
            right = solve(arr, i, j - 1, k) + 1;

        return left + right;
    }

    static int minMove(BigInteger bg, int count) {
        if (bg.equals(BigInteger.ONE))
            return count;

        int first = Integer.MAX_VALUE, sec = Integer.MAX_VALUE, last = Integer.MAX_VALUE;
        if (bg.mod(BigInteger.valueOf(2)).compareTo(BigInteger.ZERO) == 0)
            first = minMove(bg.divide(BigInteger.valueOf(2)), count + 1);

        else if (bg.mod(BigInteger.valueOf(3)).compareTo(BigInteger.ZERO) == 0)
            sec = minMove(bg.multiply(BigInteger.valueOf(2)).divide(BigInteger.valueOf(3)), count + 1);

        else if (bg.mod(BigInteger.valueOf(5)).compareTo(BigInteger.ZERO) == 0)
            last = minMove(bg.multiply(BigInteger.valueOf(4)).divide(BigInteger.valueOf(5)), count + 1);

        if (memo.containsKey(bg))
            return memo.get(bg);

        memo.put(bg, Math.min(first, Math.min(sec, last)));

        return Math.min(first, Math.min(sec, last));
    }
} public class Main {
    static Map<BigInteger, Integer> memo;

    public static void main(String[] args) throws IOException {
        Scanner sc = new Scanner(System.in);

        BigInteger a = sc.nextBigInteger();
        BigDecimal b =sc.nextBigDecimal();

        System.out.println(b.multiply(new BigDecimal(a)).toBigInteger());

    }


    static int lowerBound(int[] arr, int element) {

        int low = 0, high = arr.length - 1, ans = 0;
        while (low <= high) {
            int mid = low + (high - low) / 2;
            if (arr[mid] <= element) {
                low = mid + 1;
                ans = mid;
            } else
                high = mid - 1;

        }

        return high;
    }

    static boolean isPalindrome(String word) {
        int i = 0, j = word.length() - 1;

        while (i <= j) {
            if (word.charAt(i++) != word.charAt(j--))
                return false;
        }

        return true;
    }

    static String longestPalindrome(String[] words, String word, int i) {
        if (i >= words.length) {
            if (isPalindrome(word))
                return word;

            return "";
        }

        if (word.length() > 0 && isPalindrome(word))
            return word;
        String left = longestPalindrome(words, word + words[i], i + 1);
        String right = longestPalindrome(words, word, i + 1);

        if (left.length() > 0)
            return left;
        return right;
    }


    static int solve(int[] arr, int i, int j, int k) {
        if (i == j && arr[i] <= k)
            return 1;

        int left = 0, right = 0;
        if (arr[i] <= k)
            left = solve(arr, i + 1, j, k) + 1;

        else if (arr[j] <= k)
            right = solve(arr, i, j - 1, k) + 1;

        return left + right;
    }

    static int minMove(BigInteger bg, int count) {
        if (bg.equals(BigInteger.ONE))
            return count;

        int first = Integer.MAX_VALUE, sec = Integer.MAX_VALUE, last = Integer.MAX_VALUE;
        if (bg.mod(BigInteger.valueOf(2)).compareTo(BigInteger.ZERO) == 0)
            first = minMove(bg.divide(BigInteger.valueOf(2)), count + 1);

        else if (bg.mod(BigInteger.valueOf(3)).compareTo(BigInteger.ZERO) == 0)
            sec = minMove(bg.multiply(BigInteger.valueOf(2)).divide(BigInteger.valueOf(3)), count + 1);

        else if (bg.mod(BigInteger.valueOf(5)).compareTo(BigInteger.ZERO) == 0)
            last = minMove(bg.multiply(BigInteger.valueOf(4)).divide(BigInteger.valueOf(5)), count + 1);

        if (memo.containsKey(bg))
            return memo.get(bg);

        memo.put(bg, Math.min(first, Math.min(sec, last)));

        return Math.min(first, Math.min(sec, last));
    }
} Main


import java.io.IOException;
import java.math.BigDecimal;
import java.math.BigInteger;
import java.util.Map;
import java.util.Scanner;

public class Main {
    static Map<BigInteger, Integer> memo;

    public static void main(String[] args) throws IOException {
        Scanner sc = new Scanner(System.in);

        BigInteger a = sc.nextBigInteger();
        BigDecimal b =sc.nextBigDecimal();

        System.out.println(b.multiply(new BigDecimal(a)).toBigInteger());

    }


    static int lowerBound(int[] arr, int element) {

        int low = 0, high = arr.length - 1, ans = 0;
        while (low <= high) {
            int mid = low + (high - low) / 2;
            if (arr[mid] <= element) {
                low = mid + 1;
                ans = mid;
            } else
                high = mid - 1;

        }

        return high;
    }

    static boolean isPalindrome(String word) {
        int i = 0, j = word.length() - 1;

        while (i <= j) {
            if (word.charAt(i++) != word.charAt(j--))
                return false;
        }

        return true;
    }

    static String longestPalindrome(String[] words, String word, int i) {
        if (i >= words.length) {
            if (isPalindrome(word))
                return word;

            return "";
        }

        if (word.length() > 0 && isPalindrome(word))
            return word;
        String left = longestPalindrome(words, word + words[i], i + 1);
        String right = longestPalindrome(words, word, i + 1);

        if (left.length() > 0)
            return left;
        return right;
    }


    static int solve(int[] arr, int i, int j, int k) {
        if (i == j && arr[i] <= k)
            return 1;

        int left = 0, right = 0;
        if (arr[i] <= k)
            left = solve(arr, i + 1, j, k) + 1;

        else if (arr[j] <= k)
            right = solve(arr, i, j - 1, k) + 1;

        return left + right;
    }

    static int minMove(BigInteger bg, int count) {
        if (bg.equals(BigInteger.ONE))
            return count;

        int first = Integer.MAX_VALUE, sec = Integer.MAX_VALUE, last = Integer.MAX_VALUE;
        if (bg.mod(BigInteger.valueOf(2)).compareTo(BigInteger.ZERO) == 0)
            first = minMove(bg.divide(BigInteger.valueOf(2)), count + 1);

        else if (bg.mod(BigInteger.valueOf(3)).compareTo(BigInteger.ZERO) == 0)
            sec = minMove(bg.multiply(BigInteger.valueOf(2)).divide(BigInteger.valueOf(3)), count + 1);

        else if (bg.mod(BigInteger.valueOf(5)).compareTo(BigInteger.ZERO) == 0)
            last = minMove(bg.multiply(BigInteger.valueOf(4)).divide(BigInteger.valueOf(5)), count + 1);

        if (memo.containsKey(bg))
            return memo.get(bg);

        memo.put(bg, Math.min(first, Math.min(sec, last)));

        return Math.min(first, Math.min(sec, last));
    }
}
