import bisect n, k = map(int, input().split()) A = list(map(int, input().split())) B = sorted(A) target = 2 * k count = 0 for a in A: if a == 0: m = 0 else: m = (target + a - 1) // a idx = bisect.bisect_left(B, m) count += len(B) - idx print(count)