Problem: Devu wants to decorate his garden with flowers. He has purchased n boxes, where the i-th box contains fi flowers. All flowers in a single box are of the same color (hence they are indistinguishable). Also, no two boxes have flowers of the same color.

Now Devu wants to select exactly s flowers from the boxes to decorate his garden. Devu would like to know, in how many different ways can he select the flowers from each box? Since this number may be very large, he asks you to find the number modulo (109 + 7). 

Devu considers two ways different if there is at least one box from which different number of flowers are selected in these two ways.

Input

The first line of input contains two space-separated integers n and s (1 ≤ n ≤ 20, 0 ≤ s ≤ 1014).

The second line contains n space-separated integers f1, f2, ... fn (0 ≤ fi ≤ 1012).

Output

Output a single integer — the number of ways in which Devu can select the flowers modulo (109 + 7).

Examples

Input

2 3
1 3


Output

2


Input

2 4
2 2


Output

1


Input

3 5
1 3 2


Output

3

Note

Sample 1. There are two ways of selecting 3 flowers: {1, 2} and {0, 3}.

Sample 2. There is only one way of selecting 4 flowers: {2, 2}.

Sample 3. There are three ways of selecting 5 flowers: {1, 2, 2}, {0, 3, 2}, and {1, 3, 1}.

Solution (in JAVA):

Solution:
import java.io.BufferedInputStream;
import java.io.IOException;
import java.io.PrintWriter;
import java.util.ArrayDeque;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Comparator;
import java.util.Deque;
import java.util.HashSet;
import java.util.InputMismatchException;
import java.util.Set;

public class Main
{	
	private final int MOD = (int)(1e9 + 7);
	
	public long quickMod(long x, long p)
	{
		long ans = 1;
		x %= MOD;
		while(p > 0)
		{
			if(1 == p % 2)
			{
				ans = ans * x % MOD;
			}
			p >>= 1;
			x = x * x % MOD;
		}
		return ans;
	}
	
	public long cnm(long n, long m)
	{
		if(n < m)
		{
			return 0;
		}
		if(m > n - m)
		{
			m = n - m;
		}
		long a = 1, b = 1;
		for(long i = 0;i < m;++i)
		{
			a = a * (n - i) % MOD;
			b = b * (i + 1) % MOD;
		}
		return a * quickMod(b, MOD - 2) % MOD;
	}
	
	public long lucas(long n, long m)
	{
		long ans = 1;
		while(n > 0 && m > 0)
		{
			long a = n % MOD, b = m % MOD;
			if(a < b)
			{
				return 0;
			}
			ans = ans * cnm(a, b) % MOD;
			n /= MOD;
			m /= MOD;
		}
		return ans;
	}
	
	public void foo()
	{
		MyScanner scan = new MyScanner();
		int n = scan.nextInt();
		long s = scan.nextLong();
		long[] a = new long[n];
		for(int i = 0;i < n;++i)
		{
			a[i] = scan.nextLong();
		}
		long ans = 0;
		int m = 1 << n;
		for(int i = 0;i < m;++i)
		{
			int sign = 1;
			long sum = s;
			for(int j = 0;j < n;++j)
			{
				if((i & (1 << j)) > 0)
				{
					sum -= a[j] + 1;
					sign *= -1;
				}
			}
			if(sum >= 0)
			{
				ans += sign * lucas(sum + n - 1, n - 1);
				ans %= MOD;
			}
		}
		System.out.println((ans + MOD) % MOD);
	}
	
	public static void main(String[] args)
	{
		new Main().foo();
	}
	
	class MyScanner
	{
	    private byte[] buf = new byte[1024];
	    private int curChar;
	    private int numChars;
	    BufferedInputStream bis = new BufferedInputStream(System.in);

	    public int read() 
	    {
	        if (-1 == numChars)
	        {
	        	throw new InputMismatchException();
	        }
	        if (curChar >= numChars)
	        {
	            curChar = 0;
	            try 
	            {
	                numChars = bis.read(buf);
	            }
	            catch (IOException e)
	            {
	                throw new InputMismatchException();
	            }
	            if (numChars <= 0)
	            {
	            	return -1;
	            }
	        }
	        return buf[curChar++];
	    }

	    public int nextInt() 
	    {
	        int c = read();
	        while (isSpaceChar(c))
	        {
	        	c = read();
	        }
	        int sgn = 1;
	        if (c == '-') 
	        {
	            sgn = -1;
	            c = read();
	        }
	        int res = 0;
	        do 
	        {
	            if (c < '0' || c > '9')
	            {
	            	throw new InputMismatchException();
	            }
	            res *= 10;
	            res += c - '0';
	            c = read();
	        } while (!isSpaceChar(c));
	        return res * sgn;
	    }
	    
	    public long nextLong() 
	    {
	        int c = read();
	        while (isSpaceChar(c))
	        {
	        	c = read();
	        }
	        int sgn = 1;
	        if (c == '-') 
	        {
	            sgn = -1;
	            c = read();
	        }
	        long res = 0;
	        do 
	        {
	            if (c < '0' || c > '9')
	            {
	            	throw new InputMismatchException();
	            }
	            res *= 10;
	            res += c - '0';
	            c = read();
	        } while (!isSpaceChar(c));
	        return res * sgn;
	    }
	    
	    public String next()
	    {
	        int c = read();
	        while (isSpaceChar(c))
	        {
	        	c = read();
	        }
	        StringBuilder res = new StringBuilder();
	        do 
	        {
	            res.appendCodePoint(c);
	            c = read();
	        } while (!isSpaceChar(c));
	        return res.toString();
	    }

	    private boolean isSpaceChar(int c) 
	    {
	        return ' ' == c || '\n' == c || '\r' == c || '\t' == c || -1 == c;
	    }
	}
}