import bisect n,k = map(int,input().split()) l = sorted(map(int,input().split())) s = 0 for i in l: s += n-bisect.bisect_left(l,2*k/i) print(s)