import java.util.*; import java.lang.*; import java.io.*; public class Main { public static void main (String[] args) throws java.lang.Exception { // your code goes here // 入力 Scanner sc = new Scanner(System.in); int N = sc.nextInt(); int D = sc.nextInt(); int[] X = new int[N]; int[] V = new int[N]; for(int i = 0; i < N; i++){ X[i] = sc.nextInt(); } long Vsum = 0L; for(int i = 0; i < N; i++){ V[i] = sc.nextInt(); Vsum += V[i]; } // 計算 long time = 0L; if(D % Vsum == 0){ time = D / Vsum; }else{ time = D / Vsum + 1; } // 出力 System.out.println(time); } }