import java.util.Arrays;
import java.util.List;
import java.util.Scanner;

public class Main {
public static void main(String[] args) {
		
		Scanner keyboard = new Scanner(System.in); 
		
		int N  = keyboard.nextInt();
		int X  = keyboard.nextInt();
		
		int[]L = new int[N];
		
		for(int i = 0; i < N; i++) {
				L[i] = keyboard.nextInt();	
		}
		
		int sum = 0;
		int count = 0;
		
		for(int i = 0; i < N; i++) {
			sum += L[i];
			if(sum < X + 1){
				if(count == N-1) {
					System.out.println(i + 2);
				}else{
					count++;
				}
			}else {
				System.out.println(i + 1);
				break;
			}
		}
		
		keyboard.close();	
	}
} import java.util.Arrays; Arrays java.util import java.util.List; List java.util import java.util.Scanner; Scanner java.util public class Main {
public static void main(String[] args) {
		
		Scanner keyboard = new Scanner(System.in); 
		
		int N  = keyboard.nextInt();
		int X  = keyboard.nextInt();
		
		int[]L = new int[N];
		
		for(int i = 0; i < N; i++) {
				L[i] = keyboard.nextInt();	
		}
		
		int sum = 0;
		int count = 0;
		
		for(int i = 0; i < N; i++) {
			sum += L[i];
			if(sum < X + 1){
				if(count == N-1) {
					System.out.println(i + 2);
				}else{
					count++;
				}
			}else {
				System.out.println(i + 1);
				break;
			}
		}
		
		keyboard.close();	
	}
} Main public static void main(String[] args) {
		
		Scanner keyboard = new Scanner(System.in); 
		
		int N  = keyboard.nextInt();
		int X  = keyboard.nextInt();
		
		int[]L = new int[N];
		
		for(int i = 0; i < N; i++) {
				L[i] = keyboard.nextInt();	
		}
		
		int sum = 0;
		int count = 0;
		
		for(int i = 0; i < N; i++) {
			sum += L[i];
			if(sum < X + 1){
				if(count == N-1) {
					System.out.println(i + 2);
				}else{
					count++;
				}
			}else {
				System.out.println(i + 1);
				break;
			}
		}
		
		keyboard.close();	
	} main {
		
		Scanner keyboard = new Scanner(System.in); 
		
		int N  = keyboard.nextInt();
		int X  = keyboard.nextInt();
		
		int[]L = new int[N];
		
		for(int i = 0; i < N; i++) {
				L[i] = keyboard.nextInt();	
		}
		
		int sum = 0;
		int count = 0;
		
		for(int i = 0; i < N; i++) {
			sum += L[i];
			if(sum < X + 1){
				if(count == N-1) {
					System.out.println(i + 2);
				}else{
					count++;
				}
			}else {
				System.out.println(i + 1);
				break;
			}
		}
		
		keyboard.close();	
	} Scanner keyboard = new Scanner(System.in); keyboard new Scanner(System.in) int N  = keyboard.nextInt(); N keyboard.nextInt() keyboard.nextInt keyboard int X  = keyboard.nextInt(); X keyboard.nextInt() keyboard.nextInt keyboard int[]L = new int[N]; L new int[N] N for(int i = 0; i < N; i++) {
				L[i] = keyboard.nextInt();	
		} int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
				L[i] = keyboard.nextInt();	
		} {
				L[i] = keyboard.nextInt();	
		} L[i] = keyboard.nextInt() L[i] L i keyboard.nextInt() keyboard.nextInt keyboard int sum = 0; sum 0 int count = 0; count 0 for(int i = 0; i < N; i++) {
			sum += L[i];
			if(sum < X + 1){
				if(count == N-1) {
					System.out.println(i + 2);
				}else{
					count++;
				}
			}else {
				System.out.println(i + 1);
				break;
			}
		} int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
			sum += L[i];
			if(sum < X + 1){
				if(count == N-1) {
					System.out.println(i + 2);
				}else{
					count++;
				}
			}else {
				System.out.println(i + 1);
				break;
			}
		} {
			sum += L[i];
			if(sum < X + 1){
				if(count == N-1) {
					System.out.println(i + 2);
				}else{
					count++;
				}
			}else {
				System.out.println(i + 1);
				break;
			}
		} sum += L[i] sum L[i] L i if(sum < X + 1){
				if(count == N-1) {
					System.out.println(i + 2);
				}else{
					count++;
				}
			}else {
				System.out.println(i + 1);
				break;
			} sum < X + 1 sum X + 1 X 1 {
				if(count == N-1) {
					System.out.println(i + 2);
				}else{
					count++;
				}
			} if(count == N-1) {
					System.out.println(i + 2);
				}else{
					count++;
				} count == N-1 count N-1 N 1 {
					System.out.println(i + 2);
				} System.out.println(i + 2) System.out.println System.out System System.out i + 2 i 2 {
					count++;
				} count++ count {
				System.out.println(i + 1);
				break;
			} System.out.println(i + 1) System.out.println System.out System System.out i + 1 i 1 break; keyboard.close() keyboard.close keyboard String[] args args public class Main {
public static void main(String[] args) {
		
		Scanner keyboard = new Scanner(System.in); 
		
		int N  = keyboard.nextInt();
		int X  = keyboard.nextInt();
		
		int[]L = new int[N];
		
		for(int i = 0; i < N; i++) {
				L[i] = keyboard.nextInt();	
		}
		
		int sum = 0;
		int count = 0;
		
		for(int i = 0; i < N; i++) {
			sum += L[i];
			if(sum < X + 1){
				if(count == N-1) {
					System.out.println(i + 2);
				}else{
					count++;
				}
			}else {
				System.out.println(i + 1);
				break;
			}
		}
		
		keyboard.close();	
	}
} public class Main {
public static void main(String[] args) {
		
		Scanner keyboard = new Scanner(System.in); 
		
		int N  = keyboard.nextInt();
		int X  = keyboard.nextInt();
		
		int[]L = new int[N];
		
		for(int i = 0; i < N; i++) {
				L[i] = keyboard.nextInt();	
		}
		
		int sum = 0;
		int count = 0;
		
		for(int i = 0; i < N; i++) {
			sum += L[i];
			if(sum < X + 1){
				if(count == N-1) {
					System.out.println(i + 2);
				}else{
					count++;
				}
			}else {
				System.out.println(i + 1);
				break;
			}
		}
		
		keyboard.close();	
	}
} Main
import java.util.Arrays;
import java.util.List;
import java.util.Scanner;

public class Main {
public static void main(String[] args) {
		
		Scanner keyboard = new Scanner(System.in); 
		
		int N  = keyboard.nextInt();
		int X  = keyboard.nextInt();
		
		int[]L = new int[N];
		
		for(int i = 0; i < N; i++) {
				L[i] = keyboard.nextInt();	
		}
		
		int sum = 0;
		int count = 0;
		
		for(int i = 0; i < N; i++) {
			sum += L[i];
			if(sum < X + 1){
				if(count == N-1) {
					System.out.println(i + 2);
				}else{
					count++;
				}
			}else {
				System.out.println(i + 1);
				break;
			}
		}
		
		keyboard.close();	
	}
}