import java.util.*; class Main { static Scanner sc = new Scanner(System.in); public static void main(String[] args) { long n = sc.nextLong(); long m = sc.nextLong(); System.out.println(n/(m*1000)*1000); } }