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.math.*;
import java.util.*;

public class CODEFORCES {
	private InputStream is;
	private PrintWriter out;

	long fact[] = new long[21];
	long mod = (long) 1e9 + 7;
	long fi[] = new long[21];

	long pow(long a, long b) {
		long ans = 1;
		if (a == 0)
			return 0;
		while (b > 0) {
			if ((b & 1) == 1)
				ans = (ans * a) % mod;
			a = (a * a) % mod;
			b >>= 1;
		}
		return ans;
	}

	long ni;

	long nCr(long a) {
		long ans = 1;
		long mi = Math.min(a, ni - 1);
		long ma = mi;
		while (mi-- > 0)
			ans = (ans * ((ni + (--a)) % mod)) % mod;
		return (ans * fi[(int) ma]) % mod;
	}

	void solve() {
		int n = ni();
		ni = n;
		long s = nl();
		long val[] = new long[n];
		for (int i = 0; i < n; i++)
			val[i] = nl();
		fact[0] = 1;
		fi[0] = pow(fact[0], mod - 2);
		for (int i = 1; i <= 20; i++) {
			fact[i] = (fact[i - 1] * i) % mod;
			fi[i] = pow(fact[i], mod - 2);
		}
		HashMap<Long, Long> map = new HashMap<Long, Long>();
		map.put((long) 0, (long) 1);
		for (int i = 0; i < n; i++) {
			HashMap<Long, Long> tmp = new HashMap<Long, Long>();
			for (long p : map.keySet())
				tmp.put(p, map.get(p));
			for (long p : map.keySet()) {
				long add = p + val[i] + 1;
				if (add > s)
					continue;
				if (tmp.containsKey(add))
					tmp.put(add, (mod + tmp.get(add) - map.get(p)) % mod);
				else
					tmp.put(add, mod - map.get(p));
			}
			map = tmp;
		}
		long ans = 0;
		for (long a : map.keySet()) {
			// out.println(a + " " + map.get(a));
			ans = (ans + nCr(s - a) * map.get(a) % mod) % mod;
		}
		out.println(ans);
	}

	void soln() throws Exception {
		is = System.in;
		out = new PrintWriter(System.out);
		long s = System.currentTimeMillis();
		solve();
		out.flush();
		tr(System.currentTimeMillis() - s + "ms");
	}

	public static void main(String[] args) throws Exception {
		new CODEFORCES().soln();
	}

	// To Get Input
	// Some Buffer Methods
	private byte[] inbuf = new byte[1024];
	public int lenbuf = 0, ptrbuf = 0;

	private int readByte() {
		if (lenbuf == -1)
			throw new InputMismatchException();
		if (ptrbuf >= lenbuf) {
			ptrbuf = 0;
			try {
				lenbuf = is.read(inbuf);
			} catch (IOException e) {
				throw new InputMismatchException();
			}
			if (lenbuf <= 0)
				return -1;
		}
		return inbuf[ptrbuf++];
	}

	private boolean isSpaceChar(int c) {
		return !(c >= 33 && c <= 126);
	}

	private int skip() {
		int b;
		while ((b = readByte()) != -1 && isSpaceChar(b))
			;
		return b;
	}

	private double nd() {
		return Double.parseDouble(ns());
	}

	private char nc() {
		return (char) skip();
	}

	private String ns() {
		int b = skip();
		StringBuilder sb = new StringBuilder();
		while (!(isSpaceChar(b))) { // when nextLine, (isSpaceChar(b) && b != '
									// ')
			sb.appendCodePoint(b);
			b = readByte();
		}
		return sb.toString();
	}

	private char[] ns(int n) {
		char[] buf = new char[n];
		int b = skip(), p = 0;
		while (p < n && !(isSpaceChar(b))) {
			buf[p++] = (char) b;
			b = readByte();
		}
		return n == p ? buf : Arrays.copyOf(buf, p);
	}

	private char[][] nm(int n, int m) {
		char[][] map = new char[n][];
		for (int i = 0; i < n; i++)
			map[i] = ns(m);
		return map;
	}

	private int[] na(int n) {
		int[] a = new int[n];
		for (int i = 0; i < n; i++)
			a[i] = ni();
		return a;
	}

	private int ni() {
		int num = 0, b;
		boolean minus = false;
		while ((b = readByte()) != -1 && !((b >= '0' && b <= '9') || b == '-'))
			;
		if (b == '-') {
			minus = true;
			b = readByte();
		}

		while (true) {
			if (b >= '0' && b <= '9') {
				num = num * 10 + (b - '0');
			} else {
				return minus ? -num : num;
			}
			b = readByte();
		}
	}

	private long nl() {
		long num = 0;
		int b;
		boolean minus = false;
		while ((b = readByte()) != -1 && !((b >= '0' && b <= '9') || b == '-'))
			;
		if (b == '-') {
			minus = true;
			b = readByte();
		}

		while (true) {
			if (b >= '0' && b <= '9') {
				num = num * 10 + (b - '0');
			} else {
				return minus ? -num : num;
			}
			b = readByte();
		}
	}

	private boolean oj = System.getProperty("ONLINE_JUDGE") != null;

	private void tr(Object... o) {
		if (!oj)
			System.out.println(Arrays.deepToString(o));
	}
}