#!/usr/bin/env python3 # from typing import * import sys import io import math import collections import decimal import itertools import bisect import heapq def input(): return sys.stdin.readline()[:-1] # sys.setrecursionlimit(1000000) # _INPUT = """2 1 10 # 2 3 # """ # sys.stdin = io.StringIO(_INPUT) def get_lcm(a, b): return a * b // math.gcd(a, b) N, L, H = map(int, input().split()) C = list(map(int, input().split())) ans = 0 for s in range(1, 2**N): d = 1 m = 0 for i in range(N): if s & (1<