using System; using static System.Console; using System.Linq; using System.Collections.Generic; class Program { static int NN => int.Parse(ReadLine()); static int[] NList => ReadLine().Split().Select(int.Parse).ToArray(); static int[][] NArr(long n) => Enumerable.Repeat(0, (int)n).Select(_ => NList).ToArray(); public static void Main() { Solve(); } static void Solve() { var c = NList; var (n, m, x, y, z) = (c[0], c[1], c[2], c[3], c[4]); var a = NList; var goodcnt = 0; var goodover = 0; var list = new List(); foreach (var ai in a) { if (ai >= x) { ++goodcnt; goodover += ai - z; } else if (ai > y) { list.Add(ai); } } if (goodcnt > m) { WriteLine("Handicapped"); return; } var dp = new long[m + 1][]; for (var i = 0; i < dp.Length; ++i) dp[i] = new long[5001]; dp[goodcnt][goodover + 2500] = 1; foreach (var li in list) { for (var i = m - 1; i >= 0; --i) for (var j = 0; j < 5001; ++j) { var nj = j + li - z; if (nj < 0 || nj >= 5001) continue; dp[i + 1][nj] = dp[i + 1][nj] + dp[i][j]; } } var ans = 0L; for (var i = 1; i <= m; ++i) { ans += dp[i][2500]; } WriteLine(ans); } }