import java.util.*;
public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		
		int nn = sc.nextInt();
		int xx = sc.nextInt();
		int[] ll = new int[nn];
		long res = 0;
		int i=0;
		
		for (i=0;i<nn;i++){
			ll[i] = sc.nextInt();
		}
		
		for (i=0;i<nn;i++){
			res += ll[i];
			if(res >xx){
				break;
			}
		}
		
		System.out.print(i+1);
	}
} import java.util.*; util.* java public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		
		int nn = sc.nextInt();
		int xx = sc.nextInt();
		int[] ll = new int[nn];
		long res = 0;
		int i=0;
		
		for (i=0;i<nn;i++){
			ll[i] = sc.nextInt();
		}
		
		for (i=0;i<nn;i++){
			res += ll[i];
			if(res >xx){
				break;
			}
		}
		
		System.out.print(i+1);
	}
} Main public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		
		int nn = sc.nextInt();
		int xx = sc.nextInt();
		int[] ll = new int[nn];
		long res = 0;
		int i=0;
		
		for (i=0;i<nn;i++){
			ll[i] = sc.nextInt();
		}
		
		for (i=0;i<nn;i++){
			res += ll[i];
			if(res >xx){
				break;
			}
		}
		
		System.out.print(i+1);
	} main {
		Scanner sc = new Scanner(System.in);
		
		int nn = sc.nextInt();
		int xx = sc.nextInt();
		int[] ll = new int[nn];
		long res = 0;
		int i=0;
		
		for (i=0;i<nn;i++){
			ll[i] = sc.nextInt();
		}
		
		for (i=0;i<nn;i++){
			res += ll[i];
			if(res >xx){
				break;
			}
		}
		
		System.out.print(i+1);
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int nn = sc.nextInt(); nn sc.nextInt() sc.nextInt sc int xx = sc.nextInt(); xx sc.nextInt() sc.nextInt sc int[] ll = new int[nn]; ll new int[nn] nn long res = 0; res 0 int i=0; i 0 for (i=0;i<nn;i++){
			ll[i] = sc.nextInt();
		} i=0; i=0 i 0 i<nn i nn i++ i++ i {
			ll[i] = sc.nextInt();
		} {
			ll[i] = sc.nextInt();
		} ll[i] = sc.nextInt() ll[i] ll i sc.nextInt() sc.nextInt sc for (i=0;i<nn;i++){
			res += ll[i];
			if(res >xx){
				break;
			}
		} i=0; i=0 i 0 i<nn i nn i++ i++ i {
			res += ll[i];
			if(res >xx){
				break;
			}
		} {
			res += ll[i];
			if(res >xx){
				break;
			}
		} res += ll[i] res ll[i] ll i if(res >xx){
				break;
			} res >xx res xx {
				break;
			} break; System.out.print(i+1) System.out.print System.out System System.out i+1 i 1 String[] args args public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		
		int nn = sc.nextInt();
		int xx = sc.nextInt();
		int[] ll = new int[nn];
		long res = 0;
		int i=0;
		
		for (i=0;i<nn;i++){
			ll[i] = sc.nextInt();
		}
		
		for (i=0;i<nn;i++){
			res += ll[i];
			if(res >xx){
				break;
			}
		}
		
		System.out.print(i+1);
	}
} public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		
		int nn = sc.nextInt();
		int xx = sc.nextInt();
		int[] ll = new int[nn];
		long res = 0;
		int i=0;
		
		for (i=0;i<nn;i++){
			ll[i] = sc.nextInt();
		}
		
		for (i=0;i<nn;i++){
			res += ll[i];
			if(res >xx){
				break;
			}
		}
		
		System.out.print(i+1);
	}
} Main
import java.util.*;
public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		
		int nn = sc.nextInt();
		int xx = sc.nextInt();
		int[] ll = new int[nn];
		long res = 0;
		int i=0;
		
		for (i=0;i<nn;i++){
			ll[i] = sc.nextInt();
		}
		
		for (i=0;i<nn;i++){
			res += ll[i];
			if(res >xx){
				break;
			}
		}
		
		System.out.print(i+1);
	}
}