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.*;
import java.util.*;
public class Main {

    public static void main(String[] args) 
    {	
        InputStream inputstream = System.in;
        OutputStream outputstream = System.out;
        InputReader in = new InputReader(inputstream);
        OutputWriter out = new OutputWriter(outputstream);
        mysolver mysol = new mysolver();
        mysol.solve(in, out);
        out.close();
    }

}

class mysolver {
	public long mod = 1000000007;
	public long MOD = 1_000_000_007;
	long inv[] = new long[26];
    public void solve(InputReader in,OutputWriter out)
    {
    	PrintWriter pout = new PrintWriter(new BufferedOutputStream(System.out));
    	int n = in.readInt();
    	long s = Long.parseLong(in.readString());
    	long f[] = new long[n];
    	for(int i=0;i<n;i++)
    		f[i] = Long.parseLong(in.readString());
    	long ans = 0;
    	for(int i=1;i<=25;i++)
    		inv[i] = inverse(i);
    	for(int i=0 ;i< 1<<n ; i++)
    	{
    		int bit = Long.bitCount(i);
    		String str = Long.toBinaryString(i);
    		str = ("00000000000000000000000000000000").concat(str);
    		int sign = 0;
    		
    		if(bit%2==0)
    			sign = 1;
    		else
    			sign = -1;
    		
    		char[] ch = str.toCharArray();
    		long val = s;
    		for(int j=ch.length-1;j>ch.length-n-1;j--)
    		{
    			if(ch[j]=='1')
    			{
    				val = val - f[ch.length-1-j]-1;
    			}
    		}
    		val = val+n-1;
    		if(val < 0)
    			continue;
    		ans = ans + sign * C(val,n-1);
    		ans = ans%mod;
    		//System.out.println(ans);
    	}
    	while(ans < 0)
    		ans = ans+mod;
    	System.out.println(ans);
    	pout.close();
    }
    
    public long C(long n, long k) {
        long r = 1;
        for (long i = n; i > n - k; i--)
            r = (r * (i % MOD)) % MOD;
        long d = 1;
        for (long i = 1; i <= k; i++)
            d = (d * i) % MOD;
        return (r * inverse(d)) % MOD;
    }
    
    public long inverse(long a)
    {
    	long val = mod-2;
    	long ans = 1;
    	long mul = a;
    	while(val!=0)
    	{
    		if(val%2==1)
    		{
    			ans = (ans*mul)%mod;
    		}
    		mul = (mul*mul)%mod;
    		val = val/2;
    	}
    	return ans;
    }
}
class InputReader {
 
    private InputStream stream;
    private byte[] buf = new byte[1024];
    private int curChar;
    private int numChars;
    private SpaceCharFilter filter;
 
    public InputReader(InputStream stream) {
        this.stream = stream;
    }
 
    public int read() {
        if (numChars == -1)
            throw new InputMismatchException();
        if (curChar >= numChars) {
            curChar = 0;
            try {
                numChars = stream.read(buf);
            } catch (IOException e) {
                throw new InputMismatchException();
            }
            if (numChars <= 0)
                return -1;
        }
        return buf[curChar++];
    }
 
    public int readInt() {
        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 String readString() {
        int c = read();
        while (isSpaceChar(c))
            c = read();
        StringBuilder res = new StringBuilder();
        do {
            res.appendCodePoint(c);
            c = read();
        } while (!isSpaceChar(c));
        return res.toString();
    }
 
    public boolean isSpaceChar(int c) {
        if (filter != null)
            return filter.isSpaceChar(c);
        return isWhitespace(c);
    }
 
    public static boolean isWhitespace(int c) {
        return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
    }
 
    public String next() {
        return readString();
    }
 
    public interface SpaceCharFilter {
        public boolean isSpaceChar(int ch);
    }
}
 
class OutputWriter {
    private final PrintWriter writer;
 
    public OutputWriter(OutputStream outputStream) {
        writer = new PrintWriter(new BufferedWriter(new OutputStreamWriter(outputStream)));
    }
 
    public OutputWriter(Writer writer) {
        this.writer = new PrintWriter(writer);
    }
 
    public void close() {
        writer.close();
    }
 
    public void printLine(int i) {
        writer.println(i);
    }
}
 
class IOUtils {
 
    public static void readIntArrays(InputReader in, int[]... arrays) {
        for (int i = 0; i < arrays[0].length; i++) {
            for (int j = 0; j < arrays.length; j++)
                arrays[j][i] = in.readInt();
        }
    }
 
    }