— Hey folks, how do you like this problem?

— That'll do it. 

BThero is a powerful magician. He has got $n$ piles of candies, the $i$-th pile initially contains $a_i$ candies. BThero can cast a copy-paste spell as follows:   He chooses two piles $(i, j)$ such that $1 \le i, j \le n$ and $i \ne j$.  All candies from pile $i$ are copied into pile $j$. Formally, the operation $a_j := a_j + a_i$ is performed. 

BThero can cast this spell any number of times he wants to — but unfortunately, if some pile contains strictly more than $k$ candies, he loses his magic power. What is the maximum number of times BThero can cast the spell without losing his power?


-----Input-----

The first line contains one integer $T$ ($1 \le T \le 500$) — the number of test cases.

Each test case consists of two lines:   the first line contains two integers $n$ and $k$ ($2 \le n \le 1000$, $2 \le k \le 10^4$);  the second line contains $n$ integers $a_1$, $a_2$, ..., $a_n$ ($1 \le a_i \le k$). 

It is guaranteed that the sum of $n$ over all test cases does not exceed $1000$, and the sum of $k$ over all test cases does not exceed $10^4$.


-----Output-----

For each test case, print one integer — the maximum number of times BThero can cast the spell without losing his magic power.


-----Example-----
Input
3
2 2
1 1
3 5
1 2 3
3 7
3 2 2

Output
1
5
4



-----Note-----

In the first test case we get either $a = [1, 2]$ or $a = [2, 1]$ after casting the spell for the first time, and it is impossible to cast it again.

Difficulty: EASY

Solutions:
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	b = sorted(a)
	c = 0
	for i in range(1, n):
		c += (k - b[i]) // b[0]
	print(c)


import sys
LI = lambda : list(map(int, sys.stdin.readline().strip('\n').split()))
MI = lambda : map(int, sys.stdin.readline().strip('\n').split())
SI = lambda : sys.stdin.readline().strip('\n')
II = lambda : int(sys.stdin.readline().strip('\n'))
for _ in range(II()):
	(n, k) = MI()
	a = LI()
	(mn, ind) = (10000000, 0)
	for (i, v) in enumerate(a):
		if v < mn:
			mn = v
			ind = i
	(ans, mnn) = (0, 10000000)
	for i in range(n):
		if i != ind:
			c = (k - a[i]) // mn
			ans += c
			a[i] += c * mn
			mnn = min(mnn, a[i])
	if mn + mnn <= k:
		ans += 1
	print(ans)


import math
for i in range(int(input())):
	(n, k) = map(int, input().split())
	list = []
	io = input()
	list = io.split()
	list1 = []
	for j in list:
		list1.append(int(j))
	list1.sort()
	count = 0
	m = list1[0]
	for i in list1[1:]:
		count = count + math.floor((k - i) / m)
	print(count)


for x in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	l.sort()
	mi = l[0]
	c = 0
	for y in l[1:]:
		c += (k - y) // mi
	print(c)


import math
t = int(input())
for test in range(t):
	(n, k) = map(int, input().split())
	A = list(map(int, input().split()))
	A.sort()
	ans = 0
	for i in range(1, n):
		if A[i] > k:
			ans = 0
			break
		rem = k - A[i]
		ans += rem // A[0]
	print(ans)


def main():
	for _ in range(int(input())):
		(n, k) = map(int, input().split())
		a = sorted(list(map(int, input().split())))
		ans = 0
		for i in range(1, n):
			ans += (k - a[i]) // a[0]
		print(ans)
main()


T = int(input())
for test in range(T):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	m = min(a)
	a.remove(m)
	res = 0
	for i in a:
		res += (k - i) // m
	print(res)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	lol = [int(n) for n in input().split()]
	ans = 0
	lol.sort()
	x = lol[0]
	for i in range(1, n):
		if k - lol[i] > 0:
			ans += int((k - lol[i]) // x)
	print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	m = min(l)
	c = 0
	ans = 0
	for i in l:
		if i == m and (not c):
			c = 1
		else:
			ans += (k - i) // m
	print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	m = min(a)
	h = a.index(m)
	c = 0
	for i in range(n):
		if i != h:
			c += (k - a[i]) // m
	print(c)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	ar = list(map(int, input().split()))
	ar = sorted(ar)
	ans = 0
	for i in range(1, n):
		ans += (k - ar[i]) // ar[0]
	print(ans)


t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	count = 0
	mn = min(arr)
	minind = arr.index(mn)
	for j in range(n):
		if j != minind:
			while arr[j] + mn <= k:
				arr[j] += mn
				count += 1
	print(count)


T = int(input())
for i in range(T):
	count = 0
	(n, k) = list(map(lambda x: int(x), input().split()))
	lst = list(map(lambda x: int(x), input().split()))
	minim = min(lst)
	lst.remove(minim)
	for i in range(len(lst)):
		while lst[i] + minim <= k:
			lst[i] += minim
			count += 1
	print(count)


for _ in range(int(input())):
	(n, k) = [int(i) for i in input().split()]
	lst = [int(i) for i in input().split()]
	(pos, m) = (0, lst[0])
	for j in range(1, n):
		if lst[j] < m:
			(m, pos) = (lst[j], j)
	result = 0
	for j in range(n):
		if j != pos:
			result += (k - lst[j]) // m
	print(result)


for i in range(int(input())):
	(n, m) = map(int, input().split())
	l = list(map(int, input().split()))
	a = sorted(l)
	ans = 0
	for i in range(1, n):
		ans += (m - a[i]) // a[0]
	print(ans)


import heapq

def max_copy(a, k):
	heapq.heapify(a)
	to_copy = heapq.heappop(a)
	return sum(((k - x) // to_copy for x in a))
T = int(input().rstrip())
for _ in range(T):
	(n, k) = map(int, input().rstrip().split())
	a = list(map(int, input().rstrip().split()))
	print(max_copy(a, k))


for i in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	ans = 0
	b = min(a)
	for i in range(1, len(a)):
		if k - a[i] > 0:
			if k - a[i] >= b:
				ans += (k - a[i]) // b
	print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	m = min(a)
	index = a.index(m)
	ans = 0
	for i in range(n):
		if i == index:
			continue
		ans += (k - a[i]) // m
	print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	lis = list(map(int, input().split()))
	lis.sort()
	count = 0
	mi = lis[0]
	for i in range(1, n):
		if k > lis[i]:
			count += (k - lis[i]) // mi
	print(count)


import sys, os, io
I = io.BytesIO(os.read(0, os.fstat(0).st_size)).readline
for tc in range(1, 1 + int(I())):
	(n, k) = map(int, I().split())
	a = list(map(int, I().split()))
	a.sort()
	ans = 0
	mn = a[0]
	for x in a[2:]:
		x = k - x
		ans += x // mn
	ans += max((k - a[1]) // a[0], (k - a[0]) // a[1])
	print(ans)


for i in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	mini = min(a)
	a.sort()
	a.reverse()
	c = 0
	for i in range(n - 1):
		c = c + (k - a[i]) // mini
	print(c)


t = input()
t = int(t)
for i in range(t):
	(n, k) = input().split(' ')
	n = int(n)
	k = int(k)
	arr = list(map(int, input().rstrip().split()))
	arr.sort()
	count = 0
	for j in range(1, len(arr)):
		count = count + (k - arr[j]) // arr[0]
	print(count)


from sys import stdin
t = int(stdin.readline())
for _ in range(t):
	(n, k) = map(int, stdin.readline().split())
	arr = [int(x) for x in stdin.readline().split()]
	ans = 0
	min_index = 0
	for i in range(len(arr)):
		if arr[i] < arr[min_index]:
			min_index = i
	for j in range(len(arr)):
		if j != min_index:
			ans += (k - arr[j]) // arr[min_index]
	print(ans)


for i in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	l = 0
	for i in range(1, n):
		l += (k - a[i]) // a[0]
	print(l)


t = int(input())
for _ in range(t):
	(n, k) = [int(i) for i in input().split(' ')]
	a = [int(i) for i in input().split(' ')]
	small = min(a)
	ind = False
	ans = 0
	for i in a:
		if i > small:
			ans += (k - i) // small
		elif i == small and ind == False:
			ind = True
		else:
			ans += (k - i) // small
	print(ans)


from sys import stdin
input = stdin.readline
for _ in range(int(input())):
	(n, x) = map(int, input().split())
	a = sorted(list(map(int, input().split())), reverse=True)
	g = a.pop()
	ans = 0
	for i in a:
		ans += max(0, (x - i) // g)
	print(ans)


import sys
import os
from math import sqrt, log, log2, log10, gcd, floor, pow, sin, cos, tan, pi, inf, factorial
from copy import copy, deepcopy
import bisect
from sys import exit, stdin, stdout
from collections import Counter, defaultdict, deque
from itertools import permutations
import heapq
mod = 1000000007
iinp = lambda : int(sys.stdin.readline())
inp = lambda : sys.stdin.readline().strip()
strl = lambda : list(inp().strip().split(' '))
intl = lambda : list(map(int, inp().split(' ')))
mint = lambda : map(int, inp().split())
flol = lambda : list(map(float, inp().split(' ')))
flush = lambda : stdout.flush()

def isPrime(n):
	if n <= 1:
		return False
	if n <= 3:
		return True
	if n % 2 == 0 or n % 3 == 0:
		return False
	p = int(sqrt(n))
	for i in range(5, p + 1, 6):
		if n % i == 0 or n % (i + 2) == 0:
			return False
	return True

def solve():
	(n, k) = mint()
	arr = intl()
	arr.sort()
	ans = 0
	x = arr[0]
	for i in range(1, n):
		ans += (k - arr[i]) // x
	print(ans)
for _ in range(iinp()):
	solve()


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = sorted(list(map(int, input().split())))
	count = 0
	q = a[0]
	for i in range(1, len(a)):
		if a[i] < k:
			count += (k - a[i]) // q
	print(count)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	print(sum([(k - a[i]) // a[0] for i in range(1, len(a))]))


n = int(input())
for i in range(n):
	a = list(map(int, input().split(' ')))
	b = list(map(int, input().split(' ')))
	b.sort()
	b.reverse()
	c1 = 0
	c = min(b)
	for j in range(len(b) - 1):
		d = a[1] - b[j]
		if d > 0:
			e = d / c
			c1 += int(e)
	print(int(c1))


t = int(input())
for _ in range(t):
	(n, k) = list(map(int, input().split()))
	a = list(map(int, input().split()))
	m = min(a)
	c = 0
	ans = 0
	for i in range(n):
		if a[i] == m and c == 0:
			c = c + 1
		else:
			ans = ans + max(k - a[i], 0) // m
	print(ans)


t = int(input())
for i in range(t):
	(n, k) = [int(i) for i in input().split()]
	a = [int(i) for i in input().split()]
	e = min(a)
	o = True
	res = 0
	for j in a:
		if j == e and o:
			o = False
			continue
		res += (k - j) // e
	print(res)


t = int(input())
for i in range(0, t):
	(n, k) = list(map(int, input().split()))
	a = list(map(int, input().split()))
	d = min(a)
	a.sort()
	s = 0
	for j in range(1, n):
		s = s + (k - a[j]) // d
	print(s)


import time

def main():
	(n, k) = map(int, input().split(' '))
	a = map(int, input().split(' '))
	candies = [i for i in a]
	star = time.time()
	candies.sort()
	operation = 0
	for i in range(1, n):
		operation = operation + (k - candies[i]) // candies[0]
	return operation
n = int(input())
res = []
for i in range(n):
	res.append(main())
for i in res:
	print(i)


t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	mi = a[0]
	ans = 0
	for i in range(1, n):
		ans += (k - a[i]) // mi
	print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	spell = 0
	for i in range(1, n):
		a[i] = a[i] - k
		if a[i] < 0:
			a[i] = -1 * a[i]
			spell += a[i] // a[0]
		else:
			break
	print(spell)


for _ in range(int(input())):
	c = 0
	(n, k) = list(map(int, input().split()))
	num = list(map(int, input().split()))
	num.sort()
	a = num[0]
	for i in num[1:]:
		if k > i:
			c += (k - i) // a
	print(c)


for _ in range(int(input())):
	(n, k) = [int(i) for i in input().split()]
	list1 = [int(i) for i in input().split()]
	list1.sort()
	sum1 = 0
	for i in range(1, n):
		sum1 += int((k - list1[i]) / list1[0])
	print(int(sum1))


for x in range(int(input())):
	(n, k) = list(map(int, input().split()))
	m = list(map(int, input().split()))
	m.sort()
	l = 0
	for i in range(1, n):
		l += (k - m[i]) // m[0]
	print(l)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	v = list(map(int, input().split()))
	mai = min(v)
	mi = v.index(mai)
	cast = 0
	for i in range(n):
		if i != mi:
			cast += (k - v[i]) // mai
	print(cast)


t = int(input())
for z in range(t):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	arr.sort()
	count = 0
	for i in range(1, n):
		count = count + (k - arr[i]) // arr[0]
	print(count)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	x = min(a)
	a.sort()
	c = 0
	for i in range(n - 1, 0, -1):
		c += (k - a[i]) // x
	print(c)


from bisect import *
from collections import *
from random import *
from decimal import *
import sys
input = sys.stdin.readline

def inp():
	return int(input())

def st():
	return input().rstrip('\n')

def lis():
	return list(map(int, input().split()))

def ma():
	return map(int, input().split())
t = inp()
while t:
	t -= 1
	(n, k) = ma()
	a = lis()
	co = 0
	a.sort()
	for i in range(n):
		if i == 0 or a[i] >= k:
			continue
		co += (k - a[i]) // a[0]
	print(co)


for _ in range(0, int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	s = 0
	x = min(a)
	for i in range(0, n):
		if a[i] >= x and a[i] < k:
			s = s + (k - a[i]) // x
	s = s - (k - x) // x
	print(s)


from math import *
from bisect import bisect_left as bl
from bisect import bisect_right as br
from collections import Counter as ctr
from collections import deque as dq
from array import array
from re import search
inp = lambda : int(input())
li = lambda : list(map(int, input().split()))
lb = lambda : list(map(int, input()))
ls = lambda : list(input())
arr = lambda a: array('i', a)
bi = lambda n: bin(n).replace('0b', '')
yn = lambda f: print('NYOE S'[f::2])
sbstr = lambda a, s: search('.*'.join(a), s)

def solve(__=1):
	for _ in range(__):
		(n, k) = li()
		a = sorted(li())
		ans = 0
		for i in range(1, n):
			ans += int((k - a[i]) / a[0]) if k > a[i] else 0
		print(ans)
solve(inp())


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split(' '))
	a = list(map(int, input().split(' ')))
	a.sort()
	spells = 0
	for i in range(1, n):
		spells += (k - a[i]) // a[0]
	print(spells)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	l.sort()
	r = 0
	for i in range(1, n):
		r = r + int((k - l[i]) / l[0])
	print(r)


from sys import stdin, stdout
from collections import defaultdict
input = stdin.readline
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	l.sort()
	ans = 0
	for i in range(1, n):
		ans += (k - l[i]) // l[0]
	print(ans)


def main(n, k, a):
	x = min(a)
	index = a[x]
	i = 0
	s = 0
	while i < n:
		if i != x:
			y = k - a[i]
			z = int(y / index)
			s = s + z
		i = i + 1
	return s

def min(arr):
	index = 0
	m = arr[0]
	x = 0
	while index < len(arr):
		if arr[index] < m:
			m = arr[index]
			x = index
		index = index + 1
	return x
t = int(input())
for t_itr in range(t):
	nk = list(map(int, input().rstrip().split()))
	n = nk[0]
	k = nk[1]
	a = list(map(int, input().rstrip().split()))
	res = main(n, k, a)
	print(res)


a = int(input())
for i in range(0, a):
	(n, k) = input().split()
	st = list(map(int, input().split()))
	mini = min(st)
	ans = 0
	for j in st:
		ans = ans + (int(k) - j) // mini
	print(ans - (int(k) - mini) // mini)


for _ in ' ' * int(input()):
	(n, m) = map(int, input().split())
	a = sorted([int(x) for x in input().split() if int(x) < m])
	c = 0
	for r in a[1:]:
		c += (m - r) // a[0]
	print(c)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	lst = list(map(int, input().split()))
	index = lst.index(min(lst))
	res = 0
	for i in range(n):
		if i == index:
			continue
		res += (k - lst[i]) // min(lst)
	print(res)


import sys
input = sys.stdin.readline

def solve():
	(n, k) = map(int, input().split())
	L = list(map(int, input().split()))
	L.sort()
	cnt = 0
	i = 1
	while i < n:
		cnt += (k - L[i]) // L[0]
		i += 1
	print(cnt)
for _ in range(int(input())):
	solve()


def ii():
	return int(input())

def li():
	return list(map(int, input().split()))
t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	a = li()
	a.sort()
	count = 0
	for i in a[1:]:
		count += (k - i) // a[0]
	print(count)


import sys
for i in range(0, int(sys.stdin.readline())):
	k = int(sys.stdin.readline().split()[1])
	vlist = list(map(int, sys.stdin.readline().split()))
	vlist.sort()
	mincr = vlist[0]
	ngrnum = 0
	for i in range(1, len(vlist)):
		c = vlist[i]
		while c + mincr <= k:
			ngrnum += 1
			c += mincr
		vlist[i] = c
	nmincr = min(vlist[1:])
	while vlist[0] + nmincr <= k:
		ngrnum += 1
		vlist[0] += nmincr
	sys.stdout.write(str(ngrnum) + '\n')


import sys
import itertools

def get_line():
	return list(map(int, sys.stdin.readline().strip().split()))

def in1():
	return int(input())
for _ in range(in1()):
	(n, k) = get_line()
	a = get_line()
	t1 = min(a)
	c = 0
	for i in range(n):
		t2 = k - a[i]
		c += t2 // t1
	print(c - (k - t1) // t1)


def solve():
	t = int(input())
	for _ in range(t):
		(n, k) = map(int, input().split())
		a = list(map(int, input().split()))
		a.sort()
		maxCasts = 0
		minElement = a[0]
		for i in range(1, len(a)):
			maxCasts += (k - a[i]) // minElement
		print(maxCasts)
solve()


t = int(input())
results = []
for _ in range(t):
	(n, k) = list(map(int, input().split(' ')))
	sweets = list(map(int, input().split(' ')))
	minSweet = sweets.pop(sweets.index(min(sweets)))
	count = 0
	for i in range(n - 1):
		s = sweets[i]
		howManyCounts = max(0, (k - s) // minSweet)
		sweets[i] += howManyCounts * minSweet
		count += howManyCounts
	minSweet2 = min(sweets)
	howManyCounts = max(0, (k - minSweet) // minSweet2)
	count += howManyCounts
	results.append(count)
for res in results:
	print(res)


for t in range(int(input())):
	(n, k) = list(map(int, str.split(input())))
	a = sorted(map(int, str.split(input())))
	rslt = 0
	for i in range(1, n):
		rslt += (k - a[i]) // a[0]
	print(rslt)


PI = 3.141592653589793
INF = float('inf')
MOD = 1000000007

def add(x, y):
	return (x + y) % MOD

def sub(x, y):
	return (x - y + MOD) % MOD

def mul(x, y):
	return x * y % MOD

def gcd(x, y):
	if y == 0:
		return x
	return gcd(y, x % y)

def lcm(x, y):
	return x * y // gcd(x, y)

def power(x, y):
	res = 1
	x %= MOD
	while y != 0:
		if y & 1:
			res = mul(res, x)
		y >>= 1
		x = mul(x, x)
	return res

def mod_inv(n):
	return power(n, MOD - 2)

def prob(p, q):
	return mul(p, power(q, MOD - 2))

def ii():
	return int(input())

def li():
	return [int(i) for i in input().split()]

def ls():
	return [i for i in input().split()]
for t in range(ii()):
	t += 1
	(n, k) = li()
	a = li()
	m = min(a)
	a.remove(m)
	ans = 0
	for i in a:
		x = max(0, k - i)
		ans += x // m
	print(ans)


for _ in range(int(input())):
	(n, k) = input().split()
	(n, k) = (int(n), int(k))
	l = list(map(int, input().split()))
	m = min(l)
	c = 0
	flag = 0
	for i in range(n):
		if l[i] != m or flag == 1:
			z = k - l[i]
			if z > 0:
				c += z // m
		else:
			flag = 1
	print(c)


for t in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	(mini, count, add) = (a[0], 0, 0)
	for i in range(1, n):
		if a[i] < k:
			add = k - a[i]
			count += add // mini
	print(count)


import math
t = int(input())
for case in range(1, t + 1):
	(n, k) = list(map(int, input().split()))
	a_vals = list(map(int, input().split()))
	min_a = min(a_vals)
	max_a = max(a_vals)
	if max_a > k:
		print(0)
		continue
	first_equal = True
	casts = 0
	for val in a_vals:
		if first_equal and val == min_a:
			first_equal = False
			continue
		if val <= k:
			casts += math.floor((k - val) / min_a)
	print(casts)


from os import path
import sys
from heapq import heappush, heappop
from functools import cmp_to_key as ctk
from collections import deque, defaultdict as dd
from bisect import bisect, bisect_left, bisect_right, insort, insort_left, insort_right
from itertools import permutations
from datetime import datetime
from math import ceil, sqrt, log, gcd

def ii():
	return int(input())

def si():
	return input().rstrip()

def mi():
	return map(int, input().split())

def li():
	return list(mi())
abc = 'abcdefghijklmnopqrstuvwxyz'
mod = 1000000007
inf = float('inf')
vow = ['a', 'e', 'i', 'o', 'u']
(dx, dy) = ([-1, 1, 0, 0], [0, 0, 1, -1])

def bo(i):
	return ord(i) - ord('a')

def ceil(a, b):
	return (a + b - 1) // b
file = 1

def f():
	sys.stdout.flush()

def solve():
	for _ in range(ii()):
		(n, k) = mi()
		a = li()
		mnx = min(a)
		ans = 0
		for i in range(n):
			ans += (k - a[i]) // mnx
		ans -= (k - mnx) // mnx
		print(ans)
if path.exists('input.txt'):
	sys.stdin = open('input.txt', 'r')
	sys.stdout = open('output.txt', 'w')
else:
	input = sys.stdin.readline
solve()


import math
t = int(input())
for _ in range(t):
	(n, k) = [int(x) for x in input().split()]
	A = [int(x) for x in input().split()]
	f = math.inf
	numb = 0
	for a in sorted(A):
		if f == math.inf:
			f = a
		else:
			numb += int((k - a) / f)
	print(numb)


a = int(input())
for i in range(a):
	(n, k) = [int(x) for x in input().split()]
	a = [int(x) for x in input().split()]
	x = min(a)
	x1 = 0
	count = 0
	for j in range(n):
		if a[j] == x:
			x1 = j
			break
	for j in range(n):
		if j != x1:
			count = count + (k - a[j]) // x
	print(count)


t = int(input())
ans = []
for i in range(t):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	min_val = min(arr)
	min_index = arr.index(min_val)
	flag = 0
	spells = 0
	for i in range(len(arr)):
		if i == min_index:
			continue
		elif arr[i] > k:
			ans.append(0)
			flag = 1
			break
		else:
			spells += (k - arr[i]) // min_val
	if not flag:
		ans.append(spells)
for i in ans:
	print(i)


for _ in ' ' * int(input()):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	m = min(a)
	l = list(map(lambda x: (k - x) // m, a))
	print(sum(l) - (k - m) // m)


import sys
for _ in range(int(input())):
	(n, k) = map(int, sys.stdin.readline().split())
	arr = list(map(int, sys.stdin.readline().split()))
	arr = list(sorted(arr))
	cnt = 0
	for i in range(1, n):
		cnt += (k - arr[i]) // arr[0]
	print(cnt)


t = int(input())
for tc in range(t):
	(n, k) = map(int, input().split())
	arr = [int(z) for z in input().split()]
	mn = arr.index(min(arr))
	res = 0
	for i in range(n):
		if i == mn:
			continue
		res += (k - arr[i]) // arr[mn]
	print(res)


t = int(input())
for i in range(t):
	(n, k) = [int(x) for x in input().split()]
	a = [int(x) for x in input().split()]
	a.sort()
	m = a[0]
	a = a[1:]
	sm = 0
	for x in a:
		if x < k:
			sm += (k - x) // m
	print(sm)


testcases = int(input())
for testcase in range(testcases):
	temparr = input()
	temparr = temparr.split()
	n = int(temparr[0])
	k = int(temparr[1])
	temparr = input()
	arr = []
	temparr = temparr.split()
	for i in temparr:
		arr.append(int(i))
	mins = min(arr)
	newarr = []
	flag = 0
	for i in arr:
		if i == mins and flag == 0:
			flag = 1
			continue
		else:
			newarr.append(i)
	ans = 0
	for i in newarr:
		diff = k - i
		ans += diff // mins
	print(ans)


def main() -> None:
	for test in range(int(input())):
		(n, k) = map(int, input().split())
		a = [int(x) for x in input().split()]
		a.sort()
		ans = 0
		for i in range(1, n):
			ans += max(0, (k - a[i]) // a[0])
		print(ans)
main()


gans = []
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	u = list(map(int, input().split()))
	ans = 0
	mn = min(u)
	ok = False
	for i in range(n):
		if u[i] == mn and (not ok):
			ok = True
			continue
		ans += (k - u[i]) // mn
	gans.append(ans)
print('\n'.join(map(str, gans)))


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = sorted(list(map(int, input().split())))
	sum1 = 0
	for i in range(1, n):
		sum1 += (k - a[i]) // min(a)
	print(sum1)


for i in range(int(input())):
	(n, k) = map(int, input().split())
	piles_li = sorted(list(map(int, input().split())))
	if piles_li[-1] > k:
		print(0)
	else:
		answer = 0
		for elem in piles_li[1:]:
			curr_num = (k - elem) // piles_li[0]
			answer += curr_num
		print(answer)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	l.sort()
	m = l[0]
	su = 0
	for i in l[1:]:
		if i + m > k:
			break
		su += (k - i) // m
	print(su)


t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	s = input()
	s1 = s.split()
	count = 0
	for j in range(n):
		s1[j] = int(s1[j])
	s1.sort()
	for j in range(n - 1):
		a = (k - s1[j + 1]) // s1[0]
		count += a
	print(count)


import math
test = int(input())
for i in range(test):
	(n, k) = [int(x) for x in input().split(' ')]
	mi = k + 1
	pos = -1
	ans = 0
	a = [int(x) for x in input().split(' ')]
	for i in range(n):
		if min(mi, a[i]) < mi:
			pos = i
			mi = min(mi, a[i])
	for i in range(n):
		if i != pos:
			ans += math.floor((k - a[i]) / a[pos])
	print(ans)


import math
import collections
t = int(input())
for w in range(t):
	(n, k) = (int(i) for i in input().split())
	l = sorted([int(i) for i in input().split()])
	c = 0
	for i in range(1, n):
		c += (k - l[i]) // l[0]
	print(c)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	m = min(a)
	a.sort()
	ans = 0
	for i in range(1, n):
		ans += (k - a[i]) // m
	print(ans)


t = int(input())
for i in range(t):
	(n, k) = map(int, input().split(' '))
	l = sorted(list(map(int, input().split(' '))), reverse=True)
	copied = l.pop()
	total = sum([(k - x) // copied for x in l])
	print(total)


import math

def function(n, k, nums):
	nums.sort()
	total = 0
	for i in range(1, len(nums)):
		total += int((k - nums[i]) / nums[0])
	print(total)
t = int(input())
for k1 in range(t):
	(n, k) = map(int, input().rstrip().split())
	nums = list(map(int, input().rstrip().split()))
	function(n, k, nums)


for t in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	a = l.index(min(l))
	b = max(l)
	c = 0
	if b > k:
		print(0)
	else:
		for i in range(len(l)):
			if i != a:
				c += (k - l[i]) // l[a]
	print(c)


def solve(n, k, ar):
	ar = sorted(ar)
	mini = ar[0]
	ans = 0
	for i in range(1, n):
		diff = k - ar[i]
		ans += diff // mini
	print(ans)
t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	ar = list(map(int, input().split()))
	solve(n, k, ar)


for _ in range(int(input())):
	(x, y) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	k = a[0]
	s = 0
	i = 1
	for i in range(1, x):
		s += (y - a[i]) // k
	print(s)


def solve():
	(n, k) = map(int, input().split())
	li = list(map(int, input().split()))
	li.sort()
	ans = 0
	for i in range(n):
		temp = k - li[i]
		if i:
			ans += temp // li[0]
	print(ans)
t = int(input())
for _ in range(t):
	solve()


from sys import stdin, stdout, setrecursionlimit

class Tail_Recursion_Optimization:

	def __init__(self, RECURSION_LIMIT, STACK_SIZE):
		setrecursionlimit(RECURSION_LIMIT)
		threading.stack_size(STACK_SIZE)
		return None

class SOLVE:

	def solve(self):
		R = stdin.readline
		W = stdout.write
		ans = []
		for i in range(int(R())):
			(n, k) = [int(x) for x in R().split()]
			a = [int(x) for x in R().split()]
			a.sort()
			total = 0
			for j in range(1, n):
				total += (k - a[j]) // a[0]
			ans.append(str(total))
		W('\n'.join(ans))
		return 0

def main():
	s = SOLVE()
	s.solve()
main()


n = int(input())
for i in range(n):
	(n, k) = map(int, input().split())
	ls = list(map(int, input().split()))
	m = min(ls)
	kol_vo = 0
	t = True
	for i in range(n):
		if ls[i] != m:
			kol_vo += (k - ls[i]) // m
		elif ls[i] == m and t == False:
			kol_vo += (k - ls[i]) // m
		else:
			t = False
	print(kol_vo)


def func(n, k, arr):
	arr = sorted(arr)
	small = arr[0]
	big = arr[-1]
	res = 0
	for i in arr[1:]:
		temp = k - i
		res += temp // small
	print(res)
	return
t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	func(n, k, arr)


t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	c = 0
	l = sorted(l)
	for i in range(n - 1):
		c += (k - l[i + 1]) // l[0]
	print(c)


t = int(input())
for i in range(t):
	(n, k) = [int(i) for i in input().split()]
	a = [int(i) for i in input().split()]
	a = sorted(a)
	res = 0
	for i in range(1, n):
		res += (k - a[i]) // a[0]
	print(res)


from __future__ import division, print_function
from fractions import Fraction
import sys
import os
from io import BytesIO, IOBase
from itertools import *
import bisect
from heapq import *
from math import *
from copy import *
from collections import deque
from collections import Counter as counter
from itertools import combinations as comb
from itertools import permutations as permutate
from bisect import bisect_left as bl
from bisect import bisect_right as br
from bisect import bisect
BUFSIZE = 8192
from sys import stderr

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')

def print(*args, **kwargs):
	(sep, file) = (kwargs.pop('sep', ' '), kwargs.pop('file', sys.stdout))
	at_start = True
	for x in args:
		if not at_start:
			file.write(sep)
		file.write(str(x))
		at_start = False
	file.write(kwargs.pop('end', '\n'))
	if kwargs.pop('flush', False):
		file.flush()
if sys.version_info[0] < 3:
	(sys.stdin, sys.stdout) = (FastIO(sys.stdin), FastIO(sys.stdout))
else:
	(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
from types import GeneratorType

def iterative(f, stack=[]):

	def wrapped_func(*args, **kwargs):
		if stack:
			return f(*args, **kwargs)
		to = f(*args, **kwargs)
		while True:
			if type(to) is GeneratorType:
				stack.append(to)
				to = next(to)
				continue
			stack.pop()
			if not stack:
				break
			to = stack[-1].send(to)
		return to
	return wrapped_func
mod = 1000000007

def inp():
	return sys.stdin.readline().rstrip('\r\n')

def out(var):
	sys.stdout.write(str(var))

def lis():
	return list(map(int, inp().split()))

def stringlis():
	return list(map(str, inp().split()))

def sep():
	return map(int, inp().split())

def strsep():
	return map(str, inp().split())

def zerolist(n):
	return [0] * n

def nextline():
	out('\n')

def testcase(t):
	for p in range(t):
		solve()

def printlist(a):
	for p in range(0, len(a)):
		out(str(a[p]) + ' ')

def pow(x, y, p):
	res = 1
	x = x % p
	if x == 0:
		return 0
	while y > 0:
		if y & 1 == 1:
			res = res * x % p
		y = y >> 1
		x = x * x % p
	return res
from functools import reduce

def factors(n):
	return set(reduce(list.__add__, ([i, n // i] for i in range(1, int(n ** 0.5) + 1) if n % i == 0)))

def gcd(a, b):
	if a == b:
		return a
	while b > 0:
		(a, b) = (b, a % b)
	return a

def solve():
	(n, k) = sep()
	ar = lis()
	m = min(ar)
	te = ar.index(m)
	temp = []
	t = 1
	ans = 0
	for i in ar:
		temp.append(k - i)
	for i in range(n):
		if temp[i] < 0:
			t = -1
			break
		elif i == te:
			ans += 0
		else:
			ans += temp[i] // m
	if t == -1:
		print(0)
	else:
		print(ans)
testcase(int(inp()))


t = int(input())
while t != 0:
	(n, k) = [int(p) for p in input().split()]
	rr = [int(k) for k in input().split()]
	rr.sort()
	flag = True
	i = 1
	count = 0
	while i < n:
		rr[i] += rr[0]
		if rr[i] > k:
			i += 1
		else:
			count += 1
			continue
	print(count)
	t = t - 1


for z in range(int(input())):
	(n, k) = map(int, input().split())
	a = [int(i) for i in input().split()]
	small = min(a)
	ans = 0
	for i in range(n):
		if a[i] < k:
			ans += int((k - a[i]) / small)
	ans -= int((k - small) / small)
	print(ans)


t = int(input())
for _ in range(t):
	(n, k) = [int(a) for a in input().split()]
	list1 = [int(a) for a in input().split()]
	req = min(list1)
	list1.sort()
	list1.reverse()
	count = 0
	for x in range(len(list1) - 1):
		num = int((k - list1[x]) / req)
		count = count + num
		list1[x] = list1[x] + req * num
	if list1[-1] + list1[-2] <= k:
		count = count + 1
	print(count)


from math import floor
T = int(input())
for case in range(T):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	min = a[0]
	count = 0
	for i in range(1, len(a)):
		count += floor((k - a[i]) / min)
	print(count)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	i = 1
	ans = 0
	while i < n and a[i] < k:
		ans += (k - a[i]) // a[0]
		i += 1
	print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	array = list(map(int, input().split()))
	array.sort()
	low = array[0]
	res = 0
	for i in array[1:]:
		diff = k - i
		res += diff // low
	print(res)


t = int(input())
while t > 0:
	(n, k) = map(int, input().split())
	arr = list(map(int, input().strip().split()))[:n]
	arr.sort()
	ans = 0
	for i in range(1, n, +1):
		if arr[i] >= k:
			continue
		else:
			ans = ans + (k - arr[i]) // arr[0]
	print(ans)
	t -= 1


def copy_paste(k, arr):
	answer = 0
	minimum = min(arr)
	for i in arr:
		answer += (k - i) // minimum
	return answer - (k - minimum) // minimum
t = int(input())
for i in range(t):
	(n, k) = list(map(int, input().split()))
	arr = list(map(int, input().split()))
	print(copy_paste(k, arr))


from sys import stdin
inp = lambda : stdin.readline().strip()
t = int(inp())
for _ in range(t):
	(n, k) = [int(x) for x in inp().split()]
	a = [int(x) for x in inp().split()]
	a.sort()
	ans = 0
	minimum = float('inf')
	for i in range(1, n):
		x = (k - a[i]) // a[0]
		ans += x
		minimum = min(minimum, x * a[0] + a[i])
	ans += (k - a[0]) // minimum
	print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	L = sorted([int(x) for x in input().split()])
	C = 0
	for i in range(1, n):
		if (k - L[i]) // L[0] > 0:
			C += (k - L[i]) // L[0]
	print(C)


from __future__ import division, print_function
from fractions import Fraction
import sys
import os
from io import BytesIO, IOBase
from heapq import *
from math import gcd, factorial, floor, ceil
from copy import deepcopy
from collections import deque
from bisect import bisect_left as bl
from bisect import bisect_right as br
from bisect import bisect
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')

def print(*args, **kwargs):
	(sep, file) = (kwargs.pop('sep', ' '), kwargs.pop('file', sys.stdout))
	at_start = True
	for x in args:
		if not at_start:
			file.write(sep)
		file.write(str(x))
		at_start = False
	file.write(kwargs.pop('end', '\n'))
	if kwargs.pop('flush', False):
		file.flush()
if sys.version_info[0] < 3:
	(sys.stdin, sys.stdout) = (FastIO(sys.stdin), FastIO(sys.stdout))
else:
	(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
from types import GeneratorType

def iterative(f, stack=[]):

	def wrapped_func(*args, **kwargs):
		if stack:
			return f(*args, **kwargs)
		to = f(*args, **kwargs)
		while True:
			if type(to) is GeneratorType:
				stack.append(to)
				to = next(to)
				continue
			stack.pop()
			if not stack:
				break
			to = stack[-1].send(to)
		return to
	return wrapped_func
mod = 10 ** 9 + 7

def inp():
	return sys.stdin.readline().rstrip('\r\n')

def out(var):
	sys.stdout.write(str(var))

def lis():
	return list(map(int, inp().split()))

def stringlis():
	return list(map(str, inp().split()))

def sep():
	return map(int, inp().split())

def strsep():
	return map(str, inp().split())

def zerolist(n):
	return [0] * n

def nextline():
	out('\n')

def testcase(t):
	for pp in range(t):
		solve(pp)

def printlist(a):
	for p in range(0, len(a)):
		out(str(a[p]) + ' ')

def google(p):
	print('Case #' + str(p) + ': ', end='')

def lcm(a, b):
	return a * b // gcd(a, b)

def power(x, y, p):
	res = 1
	x = x % p
	if x == 0:
		return 0
	while y > 0:
		if y & 1 == 1:
			res = res * x % p
		y = y >> 1
		x = x * x % p
	return res

def ncr(n, r):
	return factorial(n) // (factorial(r) * factorial(max(n - r, 1)))

def isPrime(n):
	if n <= 1:
		return False
	if n <= 3:
		return True
	if n % 2 == 0 or n % 3 == 0:
		return False
	i = 5
	while i * i <= n:
		if n % i == 0 or n % (i + 2) == 0:
			return False
		i = i + 6
	return True

def solve(case):
	(n, k) = sep()
	a = lis()
	a = sorted(a)
	ans = 0
	for i in range(1, n):
		ans += (k - a[i]) // a[0]
	print(ans)
testcase(int(inp()))


t = int(input())
for q in range(t):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	p = arr.index(min(arr))
	cnt = 0
	if arr[p] > k:
		print(0)
		continue
	else:
		for i in range(len(arr)):
			if i != p:
				if arr[i] < k:
					cnt += (k - arr[i]) // arr[p]
		print(cnt)


def main(data, k):
	data = sorted(data)
	count = 0
	l = data[0]
	for i in data[1:]:
		count += (k - i) // l
	return count
t = int(input())
for _ in range(t):
	(n, k) = list(map(int, input().split()))
	data = list(map(int, input().split()))
	v = main(data, k)
	print(v)


T = int(input())
for _ in range(T):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	arr.sort()
	c = 0
	m = arr[0]
	for i in range(1, n):
		x = arr[i]
		while x < k:
			x += m
			if x <= k:
				c += 1
	print(c)


from sys import stdin

def iinput():
	return int(stdin.readline())

def minput():
	return map(int, stdin.readline().split())

def linput():
	return list(map(int, stdin.readline().split()))
t = iinput()
while t:
	t -= 1
	(n, k) = minput()
	a = linput()
	a.sort()
	ans = 0
	for i in range(1, n):
		ans += max(0, k - a[i]) // a[0]
	print(ans)


test = int(input())
for i in range(test):
	(n, k) = map(int, input().split())
	l = input().split()
	l = [int(i) for i in l]
	l.sort()
	count = 0
	k1 = min(l)
	for i in range(1, n):
		diff = k - l[i]
		count += int(diff / k1)
	print(count)


t = int(input())
for _ in range(t):
	(n, k) = input().split()
	(n, k) = (int(n), int(k))
	l = list(map(int, input().split()))
	l.sort()
	count = 0
	mn = l[0]
	for i in range(1, n):
		count += (k - l[i]) // mn
	print(count)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	l = sorted(map(int, input().split()))
	ans = 0
	for i in range(1, n):
		ans += (k - l[i]) // l[0]
	print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	cnt = 0
	arr = sorted([*map(int, input().split())])
	for i in range(1, n, 1):
		cnt += (k - arr[i]) // arr[0]
	print(cnt)


import os
import sys
from io import BytesIO, IOBase
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
for _ in range(int(input())):
	(n, k) = map(int, input().split(' '))
	l = list(map(int, input().split(' ')))
	mi = 999999999
	ith = 0
	for i in range(n):
		if l[i] < mi:
			mi = l[i]
			ith = i
	ans = 0
	for i in range(n):
		if i != ith:
			ans += (k - l[i]) // mi
	print(ans)


t = int(input())
for _ in range(t):
	(n, k) = list(map(int, input().split()))
	nums = list(map(int, input().split()))
	nums = sorted(nums)
	mn = nums[0]
	answer = 0
	for i in range(len(nums) - 1, 0, -1):
		if nums[i] <= k - mn:
			answer += (k - nums[i]) // mn
	print(answer)


import sys, math
import io, os
from bisect import bisect_left as bl, bisect_right as br, insort
from heapq import heapify, heappush, heappop
from collections import defaultdict as dd, deque, Counter

def data():
	return sys.stdin.readline().strip()

def mdata():
	return list(map(int, data().split()))

def outl(var):
	sys.stdout.write('\n'.join(map(str, var)) + '\n')

def out(var):
	sys.stdout.write(str(var) + '\n')
INF = float('inf')
mod = 10 ** 9 + 7
for _ in range(int(data())):
	(n, k) = mdata()
	a = sorted(mdata())
	t = a[0]
	ans = 0
	for i in a[1:]:
		ans += (k - i) // t
	out(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	ar = list(map(int, input().split()))
	ar.sort()
	s = 0
	for i in range(1, n):
		if ar[i] < k:
			s += (k - ar[i]) // ar[0]
		else:
			break
	print(s)


T = int(input())
for t in range(T):
	[n, k] = list(map(int, input().split()))
	l = list(map(int, input().split()))
	s = 0
	m = min(l)
	for i in range(len(l)):
		if i == l.index(m):
			continue
		x = (k - l[i]) // m
		if x > 0:
			s += x
	print(s)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	x = min(a)
	print(sum(((k - i) // x for i in a)) - (k // x - 1))


t = int(input())
while t > 0:
	(n, k) = [int(x) for x in input().split()]
	l = [int(x) for x in input().split()]
	l.sort()
	ans = 0
	for i in range(1, n):
		ans = ans + (k - l[i]) // l[0]
	print(ans)
	t -= 1


def calcualate(k, listOfTests):
	order = sorted(listOfTests)
	first = order[0]
	allOfThem = order[1:]
	magicDone = 0
	for i in allOfThem:
		magicDone += (k - i) // first
	return magicDone
for i in range(int(input())):
	(n, k) = map(int, input().split())
	listOfTests = list(map(int, input().split()))
	print(calcualate(k, listOfTests))


ncases = int(input())

def to_int(s):
	return int(s)
for case in range(ncases):
	nk = input().split(' ')
	n = int(nk[0])
	k = int(nk[1])
	candies = list(map(to_int, input().split(' ')))
	candies.sort()
	sum = 0
	for i in range(1, len(candies)):
		sum += (k - candies[i]) // candies[0]
	print(sum)


for _ in range(0, int(input())):
	ar = list(map(int, input().split()))
	arr = list(map(int, input().split()))
	n = ar[0]
	k = ar[1]
	arr.sort()
	ans = 0
	for i in range(1, n):
		if k > arr[i]:
			ans += (k - arr[i]) // arr[0]
	print(ans)


x = int(input())
for i in range(0, x):
	(n, m) = [int(a) for a in input().split()]
	ar = list(map(int, input().split()))[:n]
	s = 0
	ar.sort()
	for j in range(1, n):
		d = (m - ar[j]) // ar[0]
		if d > 0:
			s = s + d
	print(s)


test_cases = int(input())
for test_case in range(test_cases):
	(n, k) = list(map(int, input().split()))
	a = list(map(int, input().split()))
	a.sort()
	mn = a[0]
	ans = 0
	for i in range(1, n):
		ans += (k - a[i]) // mn
	print(ans)


t = int(input())
for w in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	f = min(a)
	s = 0
	for x in a:
		s += (k - x) // f
	s -= k // f - 1
	print(s)


cases = int(input())
for _ in range(cases):
	(n, k) = [int(v) for v in input().split()]
	cs = [int(v) for v in input().split()]
	cs.sort(reverse=True)
	result = 0
	for i in range(n - 1):
		result += (k - cs[i]) // cs[-1]
	print(result)


import math
ls = lambda : list(map(int, input().split()))
ip = lambda : int(input())
sip = lambda : input()
r = lambda a: range(a)
lcm = lambda a, b: abs(a * b) // math.gcd(a, b)
t = ip()
for l in r(t):
	(n, k) = ls()
	cans = ls()
	m = min(cans)
	cans.remove(m)
	spell = [(k - i) // m for i in cans]
	print(sum(spell))


T = int(input())
for t in range(T):
	(n, k) = [int(i) for i in input().split()]
	A = sorted([int(i) for i in input().split()])
	if len(A) == 1:
		print(0)
	else:
		ans = 0
		for i in range(1, n):
			ans += (k - A[i]) // A[0]
		print(ans)


def test():
	t = int(input())
	for i in range(t):
		(n, k) = input().split()
		(n, k) = (int(n), int(k))
		a = input().split()
		pos = 0
		men = int(a[0])
		for j in range(1, n):
			if int(a[j]) < men:
				men = int(a[j])
				pos = j
		ans = 0
		for j in range(n):
			if j != pos:
				ans += (k - int(a[j])) // men
		print(ans)
test()


from datetime import datetime
import datetime
import random
for _ in range(int(input())):
	n: object
	(n, k) = [int(x) for x in input().split()]
	L = [int(x) for x in input().split()]
	L.sort()
	s = 0
	for i in range(1, n):
		s += (k - L[i]) // L[0]
	print(s)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	l = sorted(list(map(int, input().split())))
	x = l.pop(0)
	ans = 0
	for i in l:
		ans += (k - i) // x
	print(ans)


from fractions import Fraction
import bisect
import os
import io
from collections import Counter
import bisect
from collections import defaultdict
import math
import random
import heapq
from math import sqrt
import sys
from functools import reduce, cmp_to_key
from collections import deque
import threading
from itertools import combinations
from io import BytesIO, IOBase
from itertools import accumulate
from queue import Queue

def input():
	return sys.stdin.readline().strip()

def iinput():
	return int(input())

def tinput():
	return input().split()

def rinput():
	return map(int, tinput())

def rlinput():
	return list(rinput())
mod = int(1000000000.0) + 7

def factors(n):
	return set(reduce(list.__add__, ([i, n // i] for i in range(1, int(n ** 0.5) + 1) if n % i == 0)))
t = 1
t = iinput()
for _ in range(t):
	(n, k) = rinput()
	a = rlinput()
	val = min(a)
	ans = 0
	for i in a:
		ans += (k - i) // val
	ans -= (k - val) // val
	print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	liczby = sorted(list(map(int, input().split())))
	doda = liczby.pop(0)
	wynik = 0
	while liczby[0] <= k - doda:
		for x in range(n - 1):
			if liczby[x] <= k - doda:
				wynik += 1
				liczby[x] += doda
	print(wynik)


t = int(input())
while t > 0:
	t -= 1
	(n, k) = map(int, input().split())
	a = list(map(int, input().strip().split()))
	a.sort()
	s = 0
	for i in range(1, n):
		s += (k - a[i]) // a[0]
	print(s)


from math import ceil, floor
t = int(input())
for tt in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	ans = 0
	for ai in a[1:]:
		if ai < k:
			ans += floor((k - ai) / a[0])
	print(ans)


import os, sys
from io import IOBase, BytesIO
py2 = round(0.5)
if py2:
	from future_builtins import ascii, filter, hex, map, oct, zip
	range = xrange
BUFSIZE = 8192

class FastIO(BytesIO):
	newlines = 0

	def __init__(self, file):
		self._file = file
		self._fd = file.fileno()
		self.writable = 'x' in file.mode or 'w' in file.mode
		self.write = super(FastIO, self).write if self.writable else None

	def _fill(self):
		s = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
		self.seek((self.tell(), self.seek(0, 2), super(FastIO, self).write(s))[0])
		return s

	def read(self):
		while self._fill():
			pass
		return super(FastIO, self).read()

	def readline(self):
		while self.newlines == 0:
			s = self._fill()
			self.newlines = s.count(b'\n') + (not s)
		self.newlines -= 1
		return super(FastIO, self).readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.getvalue())
			(self.truncate(0), self.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		if py2:
			self.write = self.buffer.write
			self.read = self.buffer.read
			self.readline = self.buffer.readline
		else:
			self.write = lambda s: self.buffer.write(s.encode('ascii'))
			self.read = lambda : self.buffer.read().decode('ascii')
			self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
import sys

class ostream:

	def __lshift__(self, a):
		sys.stdout.write(str(a))
		return self
cout = ostream()
endl = '\n'

def solve():
	t = int(input())
	for _ in range(t):
		(n, k) = map(int, input().split())
		arr = list(map(int, input().split()))
		mn = min(arr)
		arr.sort()
		res = 0
		for i in range(1, len(arr)):
			res += (k - arr[i]) // mn
		cout << res << endl

def main():
	solve()
main()


t = int(input())
i = 0
while i < t:
	nk = list(map(int, input().split()))
	n = nk[0]
	k = nk[1]
	a = list(map(int, input().split()))
	answer = 0
	Min = 10001
	index = 0
	IND = 0
	while index < n:
		if a[index] < Min:
			Min = a[index]
			IND = index
		index += 1
	index = 0
	const = k - Min
	while index < n:
		if a[index] <= const and index != IND:
			answer += (k - a[index]) // Min
		index += 1
	print(answer)
	i += 1


for i in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	m = min(a)
	ans = 0
	ok = False
	for e in a:
		if e == m and (not ok):
			ok = True
			continue
		ans += int((k - e) / m)
	print(ans)


t = int(input())
for __ in range(t):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	arr.sort()
	min_val = arr[0]
	cast_num = 0
	for other in arr[1:]:
		cast_num += (k - other) // min_val
	print(cast_num)


x = int(input())
for z in range(x):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	l.sort()
	if l[1] >= k:
		print(0)
	else:
		ans = 0
		for i in range(1, n):
			ans += (k - l[i]) // l[0]
		print(ans)


import heapq
TC = int(input())
for tc in range(TC):
	(N, K) = map(int, input().split())
	A = list(map(int, input().split()))
	A.sort()
	result = 0
	if A[-1] > K:
		print(0)
		continue
	if N > 2:
		max_n = A[0]
		for a in A[2:]:
			result += max((K - a) // max_n, 0)
	a = A[0]
	b = A[1]
	r1 = max((K - b) // a, 0)
	r2 = 0
	while b <= K:
		(a, b) = (b, a + b)
		r2 += 1
	print(result + max(r1, r2 - 1))


import sys
input = sys.stdin.readline

def inInt():
	return int(input())

def inStr():
	return input().strip('\n')

def inIList():
	return list(map(int, input().split()))

def inSList():
	return input().split()

def bsearch(nums, target):
	N = len(nums or [])
	l = 0
	r = N - 1
	while l <= r:
		mid = (l + r) // 2
		if nums[mid] < target:
			l = mid + 1
		elif nums[mid] > target:
			r = mid - 1
		else:
			return (None, mid, None)
	return (r if r >= 0 else None, None, l if l <= N - 1 else None)

def yesOrNo(val):
	print('YES' if val else 'NO')

def printSpacedArray(nums):
	print(*nums)

def solve():
	(n, k) = inIList()
	nums = inIList()
	m = min(nums)
	nums.remove(m)
	count = 0
	for i in nums:
		count += (k - i) // m
	print(count)
tests = inInt()
for case in range(tests):
	solve()


T = int(input())
for i in range(T):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	m = a[0]
	c = 0
	for j in range(1, n):
		c += (k - a[j]) // m
	print(c)


for _ in range(int(input())):
	(n, k) = list(map(int, input().split()))
	arr = list(map(int, input().split()))
	arr.sort()
	it = 0
	for i in range(1, n):
		while arr[i] + arr[0] <= k:
			arr[i] += arr[0]
			it += 1
	print(it)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	ls = [int(a) for a in input().split()]
	mn = min(ls)
	ls.remove(mn)
	ctr = 0
	for i in range(n - 1):
		ctr += int((k - ls[i]) // mn)
	print(ctr)


for t in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	mi = min(a)
	im = a.index(mi)
	diff = 0
	for i in range(n):
		if i != im and a[i] < k:
			diff += (k - a[i]) // mi
	print(diff)


for i in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	m = min(a)
	a.remove(min(a))
	n = []
	for i in a:
		n.append((k - i) // m)
	print(sum(n))


from sys import stdin
T = int(stdin.readline())
for _ in range(T):
	(n, k) = map(int, stdin.readline().strip().split())
	a = list(map(int, stdin.readline().strip().split()))
	amin = index_min = min(range(len(a)), key=a.__getitem__)
	total = 0
	for i in range(n):
		if i != amin:
			diff = k - a[i]
			total += diff // a[amin]
	print(total)


def sol(a, n, k):
	min = a[0]
	id = 0
	for i in range(n):
		if a[i] < min:
			min = a[i]
			id = i
	re = 0
	for i in range(n):
		if i != id:
			re += (k - a[i]) // min
	return re
tc = int(input())
for _ in range(tc):
	IN = input().split(' ')
	n = int(IN[0])
	k = int(IN[1])
	a = list(map(lambda x: int(x), input().split(' ')))
	re = sol(a, n, k)
	print(str(re))


from sys import stdin, stdout
input = stdin.readline
for _ in range(int(input())):
	(n, p) = map(int, input().split())
	arr = list(map(int, input().split()))
	ans = 0
	x = min(arr)
	for d in arr:
		k = max(p - d, 0)
		ans += k // x
	print(ans - max(p - x, 0) // x)


t = int(input())
for j in range(t):
	(n, t) = map(int, input().split())
	l = list(map(int, input().split()))
	l.sort()
	a = l[0]
	ans = 0
	for i in range(1, n):
		if t > l[i]:
			ans += (t - l[i]) // a
	print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	l.sort()
	i = 0
	j = 1
	ans = 0
	while j < n:
		required = (k - l[j]) // l[i]
		if l[j] + required * l[i] <= k:
			ans += required
		j += 1
	print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	m = min(a)
	s = 0
	a.remove(m)
	for i in a:
		if i < k:
			s += (k - i) // m
	print(s)


for _ in range(int(input())):
	(a, b) = map(int, input().split())
	list1 = list(map(int, input().split()))
	list1.sort()
	(i, j) = (0, len(list1) - 1)
	ans = 0
	while i < j:
		if list1[j] < b:
			ans += (b - list1[j]) // list1[i]
		j -= 1
	print(ans)


for u in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	l.sort()
	c = 0
	for i in range(1, n):
		c += (k - l[i]) // l[0]
	print(c)


import math

def times(arr, k):
	minIdx = 0
	for i in range(1, len(arr)):
		if arr[i] < arr[minIdx]:
			minIdx = i
	count = 0
	for i in range(len(arr)):
		if i == minIdx:
			continue
		count += math.ceil((k - arr[i]) // arr[minIdx])
	return count
T = int(input())
for t in range(T):
	(n, k) = [int(i) for i in input().split(' ')]
	arr = [int(i) for i in input().split(' ')]
	print(times(arr, k))


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	m = min(arr)
	index = arr.index(m)
	s = 0
	for i in range(n):
		if arr[i] != m or index != i:
			s += (k - arr[i]) // m
	print(s)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	ans = 0
	p = a[0]
	for i in range(1, n):
		s = k - a[i]
		ans = ans + s // p
	print(ans)


t = int(input())
for _ in range(t):
	inp = list(map(int, input().split()))
	k = inp[1]
	arr = list(map(int, input().split()))
	m = min(arr)
	z = arr.index(m)
	ans = 0
	for i in range(len(arr)):
		if i != z:
			ans += (k - arr[i]) // m
	print(ans)


def solution(arr, k):
	ans = 0
	minEle = min(arr)
	meinEleIndex = arr.index(minEle)
	for i in range(len(arr)):
		if i == meinEleIndex:
			pass
		else:
			gap = k - arr[i]
			if gap > 0:
				ans += gap // minEle
	print(ans)
for t in range(int(input())):
	(n, k) = map(int, input().split())
	arr = [int(i) for i in input().split()]
	solution(arr, k)


from sys import *
from math import *
t = int(stdin.readline())
for _ in range(t):
	(n, k) = map(int, stdin.readline().split())
	a = list(map(int, stdin.readline().split()))
	a.sort()
	ans = 0
	for i in range(1, n):
		if a[i] < k:
			x = k - a[i]
			ans += x // a[0]
	print(ans)


for t in range(int(input())):
	(n, k) = map(int, input().split())
	A = list(map(int, input().split()))
	l = min(A)
	A.remove(l)
	c = 0
	for i in A:
		c += (k - i) // l
	print(c)


t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	x = 0
	for i in range(n - 1, 0, -1):
		if a[i] + a[0] <= k:
			x = x + (k - a[i]) // a[0]
	print(x)


T = int(input())
ans_ls = [0] * T
for t in range(T):
	(N, K) = map(int, input().split())
	a_ls = list(map(int, input().split()))
	a_ls.sort()
	times = 0
	for i in range(1, N):
		times += (K - a_ls[i]) // a_ls[0]
	ans_ls[t] = times
for ans in ans_ls:
	print(ans)


for _ in ' ' * int(input()):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	mn = min(a)
	x = a.index(mn)
	cnt = 0
	for i in range(n):
		if i != x:
			cnt += (k - a[i]) // mn
			if (k - a[i]) // mn == k:
				break
	print(cnt)


t = int(input())
res = []
for i in range(t):
	(n, k) = list(map(int, input().split()))
	a = list(map(int, input().split()))
	m = min(a)
	a.remove(m)
	res.append(0)
	for e in a:
		res[-1] += (k - e) // m
for p in res:
	print(p)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	b = a.index(min(a))
	s = 0
	for i in range(n):
		if i == b or a[i] >= k:
			continue
		s += abs(k - a[i]) // a[b]
	print(s)


for i in range(int(input())):
	a = [int(_) for _ in input().split()]
	b = sorted([int(_) for _ in input().split()])
	c = 0
	for num in b[1:]:
		c += (a[1] - num) // b[0]
	print(c)


from math import *
import threading
import sys

def fact(x):
	if x == 0:
		return 1
	else:
		return x * fact(x - 1)

def lower_bound(li, num):
	answer = -1
	start = 0
	end = len(li) - 1
	while start <= end:
		middle = (end + start) // 2
		if li[middle] >= num:
			answer = middle
			end = middle - 1
		else:
			start = middle + 1
	return answer

def upper_bound(li, num):
	answer = -1
	start = 0
	end = len(li) - 1
	while start <= end:
		middle = (end + start) // 2
		if li[middle] <= num:
			answer = middle
			start = middle + 1
		else:
			end = middle - 1
	return answer

def abs(x):
	return x if x >= 0 else -x

def binary_search(li, val, lb, ub):
	ans = 0
	while lb <= ub:
		mid = (lb + ub) // 2
		if li[mid] > val:
			ub = mid - 1
		elif val > li[mid]:
			lb = mid + 1
		else:
			ans = 1
			break
	return ans

def kadane(x):
	sum_so_far = 0
	current_sum = 0
	for i in x:
		current_sum += i
		if current_sum < 0:
			current_sum = 0
		else:
			sum_so_far = max(sum_so_far, current_sum)
	return sum_so_far

def pref(li):
	pref_sum = [0]
	for i in li:
		pref_sum.append(pref_sum[-1] + i)
	return pref_sum

def graph(n, m):
	adj = dict()
	for i in range(1, n + 1):
		adj.setdefault(i, 0)
	for i in range(m):
		(a, b) = map(int, input().split())
		adj[a] += 1
		adj[b] += 1
	return adj

def SieveOfEratosthenes(n):
	prime = [True for i in range(n + 1)]
	p = 2
	li = []
	while p * p <= n:
		if prime[p] == True:
			for i in range(p * p, n + 1, p):
				prime[i] = False
		p += 1
	for p in range(2, len(prime)):
		if prime[p]:
			li.append(p)
	return li
INF = 1000000000.0
primes = SieveOfEratosthenes(1300000)
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	ans = 0
	for i in range(1, n):
		ans += (k - a[i]) // a[0]
	print(ans)


t = int(input())
for _ in range(t):
	(n, k) = (int(x) for x in input().split())
	a = list((int(x) for x in input().split()))
	m = a.pop(a.index(min(a)))
	count = 0
	for i in a:
		d = (k - i) // m
		count += d
	print(count)


for i in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	m = min(l)
	mi = l.index(m)
	ans = 0
	for i in range(n):
		if i != mi:
			ans += (k - l[i]) // m
	print(ans)


Q = int(input())
for q in range(0, Q):
	A = list(map(int, input().split()))
	a = list(map(int, input().split()))
	n = A[0]
	k = A[1]
	ans = 0
	Min = 100000
	I = 0
	II = 0
	while I < n:
		if a[I] < Min:
			Min = a[I]
			II = I
		I += 1
	for j in range(0, n):
		if a[j] + Min <= k and j != II:
			ans += (k - a[j]) // Min
		I += 1
	print(ans)


sbdh = int(input())
for msd in range(sbdh):
	(n, k) = input().split()
	(n, k) = (int(n), int(k))
	ai = input().split()
	count = 0
	x = 0
	for oio in range(n):
		ai[oio] = int(ai[oio])
	ai.sort()
	while len(ai) > 1:
		m = k - ai[1]
		x = m // ai[0]
		count = count + x
		ai.remove(ai[1])
	print(count)


T = int(input())
for i in range(T):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	mn = min(a)
	ind = a.index(mn)
	del a[ind]
	ans = 0
	for i in a:
		ans += (k - i) // mn
	print(ans)


T = int(input())
while T != 0:
	(n, k) = [int(i) for i in input().split()]
	v = [int(i) for i in input().split()]
	v.sort()
	f = v[0]
	sum = 0
	for i in range(1, n):
		p = k - v[i]
		q = int(p / f)
		sum += q
	print(sum)
	T -= 1


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = [int(i) for i in input().split()]
	m = min(a)
	ind = a.index(m)
	del a[ind]
	counter = 0
	for num in a:
		while num <= k:
			num += m
			counter += 1
		counter -= 1
	print(counter)


t = int(input())
for i in range(t):
	(n, k) = list(map(int, input().split()))
	a = list(map(int, input().split()))
	m = min(a)
	idx = a.index(m)
	c = 0
	for j in range(n):
		if a[j] < k and j != idx:
			c += (k - a[j]) // m
	print(c)


for j in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	y = 0
	for i in range(1, n):
		if a[y] > a[i]:
			y = i
	t = 0
	for i in range(n):
		if i != y:
			t += (k - a[i]) // a[y]
			a[i] += (k - a[i]) // a[y] * a[y]
	p = y - 1
	if p < 0:
		p = n - 1
	for i in range(n):
		if a[p] > a[i] and i != y:
			p = i
	if a[y] + a[p] <= k:
		t += 1
	print(t)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	l.sort()
	ans = 0
	ref = l[0]
	for i in range(1, n):
		if l[i] >= k:
			continue
		dif = k - l[i]
		ans += dif // ref
	print(ans)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().strip().split())
	arr = list(map(int, input().strip().split()))[:n]
	arr = sorted(arr)
	count = 0
	for i in range(1, n):
		count += (k - arr[i]) // arr[0]
	print(count)


import sys, math
from collections import deque, defaultdict
import operator as op
from functools import reduce
sys.setrecursionlimit(10 ** 6)
I = sys.stdin.readline

def ii():
	return int(I().strip())

def li():
	return list(map(int, I().strip().split()))

def mi():
	return map(int, I().strip().split())

def ncr(n, r):
	r = min(r, n - r)
	numer = reduce(op.mul, range(n, n - r, -1), 1)
	denom = reduce(op.mul, range(1, r + 1), 1)
	return numer // denom

def gcd(x, y):
	while y:
		(x, y) = (y, x % y)
	return x

def main():
	ans = ''
	for _ in range(ii()):
		(n, k) = mi()
		arr = sorted(li())
		cnt = 0
		for i in range(1, n):
			tmp = (k - arr[i]) // arr[0]
			cnt += tmp
		ans += str(cnt) + '\n'
	print(ans)
main()


import sys, os, io

def rs():
	return sys.stdin.readline().rstrip()

def ri():
	return int(sys.stdin.readline())

def ria():
	return list(map(int, sys.stdin.readline().split()))

def ws(s):
	sys.stdout.write(s + '\n')

def wi(n):
	sys.stdout.write(str(n) + '\n')

def wia(a):
	sys.stdout.write(' '.join([str(x) for x in a]) + '\n')
import math, datetime, functools, itertools, operator, bisect, fractions
from collections import deque, defaultdict, OrderedDict, Counter
from fractions import Fraction
from decimal import Decimal
N = 10005
factorialNumInverse = [None] * (N + 1)
naturalNumInverse = factorialNumInverse.copy()
fact = factorialNumInverse.copy()

def InverseofNumber(p):
	naturalNumInverse[0] = naturalNumInverse[1] = 1
	for i in range(2, N + 1, 1):
		naturalNumInverse[i] = naturalNumInverse[p % i] * (p - int(p / i)) % p

def InverseofFactorial(p):
	factorialNumInverse[0] = factorialNumInverse[1] = 1
	for i in range(2, N + 1, 1):
		factorialNumInverse[i] = naturalNumInverse[i] * factorialNumInverse[i - 1] % p

def factorial(p):
	fact[0] = 1
	for i in range(1, N + 1):
		fact[i] = fact[i - 1] * i % p

def Binomial(N, R, p):
	ans = fact[N] * factorialNumInverse[R] % p * factorialNumInverse[N - R] % p
	return ans

def main():
	starttime = datetime.datetime.now()
	if os.path.exists('input.txt'):
		sys.stdin = open('input.txt', 'r')
		sys.stdout = open('output.txt', 'w')
	for _ in range(ri()):
		(n, k) = ria()
		a = ria()
		a = sorted(a)
		z = a[0]
		ans = 0
		for i in range(1, n):
			if k > a[i]:
				ans += (k - a[i]) // z
		print(ans)
	endtime = datetime.datetime.now()
	time = (endtime - starttime).total_seconds() * 1000
	if os.path.exists('input.txt'):
		print('Time:', time, 'ms')

class FastReader(io.IOBase):
	newlines = 0

	def __init__(self, fd, chunk_size=1024 * 8):
		self._fd = fd
		self._chunk_size = chunk_size
		self.buffer = io.BytesIO()

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, self._chunk_size))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self, size=-1):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, self._chunk_size if size == -1 else size))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

class FastWriter(io.IOBase):

	def __init__(self, fd):
		self._fd = fd
		self.buffer = io.BytesIO()
		self.write = self.buffer.write

	def flush(self):
		os.write(self._fd, self.buffer.getvalue())
		(self.buffer.truncate(0), self.buffer.seek(0))

class FastStdin(io.IOBase):

	def __init__(self, fd=0):
		self.buffer = FastReader(fd)
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')

class FastStdout(io.IOBase):

	def __init__(self, fd=1):
		self.buffer = FastWriter(fd)
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.flush = self.buffer.flush
sys.stdin = FastStdin()
sys.stdout = FastStdout()
main()


T = int(input())
res = list()
for i in range(T):
	(n, k) = tuple(map(int, input().split()))
	x = list(map(int, input().split()))
	x.sort()
	small = x[0]
	x = x[1:]
	sum = 0
	for j in range(len(x)):
		sum = sum + int((k - x[j]) / small)
	res.append(sum)
for i in range(len(res)):
	print(res[i])


for _ in range(int(input())):
	k = list(map(int, input().split()))
	a = list(map(int, input().split()))
	s = min(a)
	a.pop(a.index(s))
	ans = 0
	for elem in a:
		t = (k[1] - elem) // s
		if t > 0:
			ans += t
	print(ans)


t = int(input())
for i in range(t):
	(n, k) = list(map(int, input().split()))
	a = list(map(int, input().split()))
	least = min(a)
	a.remove(least)
	count = 0
	for j in a:
		c = j
		c += least
		while c <= k:
			count += 1
			c += least
	print(count)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	lis = list(map(int, input().split()))
	output = 0
	min1 = min(lis)
	for i in lis:
		output += (k - i) // min1
	output -= (k - min1) // min1
	print(output)


import time, math as mt, bisect as bs, sys
from sys import stdin, stdout
from collections import deque
from fractions import Fraction
from collections import Counter
from collections import OrderedDict
pi = 3.141592653589793

def II():
	return int(stdin.readline())

def IP():
	return map(int, stdin.readline().split())

def L():
	return list(map(int, stdin.readline().split()))

def P(x):
	return stdout.write(str(x) + '\n')

def PI(x, y):
	return stdout.write(str(x) + ' ' + str(y) + '\n')

def lcm(a, b):
	return a * b // gcd(a, b)

def gcd(a, b):
	if a == 0:
		return b
	elif b == 0:
		return a
	if a > b:
		return gcd(a % b, b)
	else:
		return gcd(a, b % a)

def bfs(adj, v):
	visited = [False] * (v + 1)
	q = deque()
	while q:
		pass

def sieve():
	li = [True] * (2 * 10 ** 5 + 5)
	(li[0], li[1]) = (False, False)
	for i in range(2, len(li), 1):
		if li[i] == True:
			for j in range(i * i, len(li), i):
				li[j] = False
	prime = []
	for i in range(2 * 10 ** 5 + 5):
		if li[i] == True:
			prime.append(i)
	return prime

def setBit(n):
	count = 0
	while n != 0:
		n = n & n - 1
		count += 1
	return count
mx = 10 ** 7
spf = [mx] * (mx + 1)

def SPF():
	spf[1] = 1
	for i in range(2, mx + 1):
		if spf[i] == mx:
			spf[i] = i
			for j in range(i * i, mx + 1, i):
				if i < spf[j]:
					spf[j] = i
	return

def readTree(n, e):
	adj = [set() for i in range(n + 1)]
	for i in range(e):
		(u1, u2) = IP()
		adj[u1].add(u2)
	return adj
mod = 10 ** 9 + 7

def solve():
	(n, k) = IP()
	a = L()
	a.sort()
	x = a[0]
	ans = 0
	for i in range(1, n):
		ans += (k - a[i]) // x
	print(ans)
	return
t = II()
for i in range(t):
	solve()


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	mn = min(a)
	idx = a.index(mn)
	a[idx] = k
	res = 0
	for i in a:
		res += max(0, k - i) // mn
	print(res)


t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	l.sort()
	s = 0
	new = []
	for i in range(1, n):
		new.append(k - l[i])
	for i in range(len(new)):
		s += new[i] // l[0]
	print(s)


import math
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	total = 0
	for i in a[1:]:
		u = k - i
		total += u // a[0]
	print(total)


t = int(input())
for _ in range(t):
	(n, k) = list(map(int, input().split()))
	arr = list(map(int, input().split()))
	arr.sort()
	res = 0
	for i in range(1, len(arr)):
		res += (k - arr[i]) // min(arr)
	print(res)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	l.sort()
	c = 0
	for i in range(1, len(l)):
		if l[i] + l[0] > k:
			break
	for j in range(1, i + 1):
		c += (k - l[j]) // l[0]
	print(c)


for _ in range(int(input())):
	(n, k) = list(map(int, input().split()))
	arr = sorted(list(map(int, input().split())))
	count = 0
	for j in arr[1:]:
		if j <= k:
			count += (k - j) // arr[0]
	print(count)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	data = [int(x) for x in input().split()]
	temp = min(data)
	data.remove(temp)
	ans = 0
	for q in data:
		if q < k:
			ans += (k - q) // temp
	print(ans)


T = int(input())
for i in range(T):
	(n, k) = list(map(int, input().split()))
	a = sorted([int(ai) for ai in input().split()])
	n_spells = 0
	for j in range(1, n):
		n_spells += (k - a[j]) // a[0]
	print(n_spells)


R = lambda : map(int, input().split())
(t,) = R()
exec(t * 'n,k=R();x,*a=sorted(R());print(sum((k-y)//x for y in a));')


T = int(input())
for _ in range(T):
	(n, k) = map(int, input().split())
	ai = [int(x) for x in input().split()]
	x = min(ai)
	y = ai.index(x)
	del ai[y]
	times = 0
	for i in range(len(ai)):
		while ai[i] <= k - x:
			times += 1
			ai[i] += x
	print(times)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	li = list(map(int, input().split()))
	(mn, mnIndx) = (1000000000.0, -1)
	for i in range(n):
		if li[i] < mn:
			(mnIndx, mn) = (i, li[i])
	ans = 0
	j = n - 1
	while j >= 0:
		if li[j] + mn <= k and j != mnIndx:
			ans += (k - li[j]) // mn
			temp = (k - li[j]) // mn
			li[j] += temp * mn
		else:
			j -= 1
	print(ans)


def solve():
	(n, k) = [int(i) for i in input().split()]
	a = [int(i) for i in input().split()]
	mini = a[0]
	minindex = 0
	for i in range(1, n):
		if mini > a[i]:
			minindex = i
			mini = a[i]
	count = 0
	for i in range(n):
		if i != minindex and a[i] < k:
			count += (k - a[i]) // mini
	print(count)
	return
t = int(input())
while t > 0:
	solve()
	t -= 1


import math
n = int(input())
for i in range(n):
	s = input().split(' ')
	n = int(s[0])
	m = int(s[1])
	s1 = input().split(' ')
	a = []
	for c in s1:
		a.append(int(c))
	b = min(a)
	a.sort()
	sum1 = 0
	for i in range(1, len(a)):
		sum1 += int((m - a[i]) / b)
	print(sum1)


def f(n, k, a):
	a = sorted(a)
	s = a[0]
	tricks = 0
	for (index, i) in enumerate(a[1:]):
		tricks += (k - i) // s
	return tricks
t = int(input())
for testcase in range(t):
	(n, k) = [int(x) for x in input().split()]
	a = [int(x) for x in input().split()]
	print(f(n, k, a))


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	mi = l[0]
	c = 0
	for i in range(1, n):
		if mi > l[i]:
			c = i
			mi = l[i]
	ans = 0
	for i in range(n):
		if i == c:
			continue
		else:
			ans = ans + (k - l[i]) // mi
	print(ans)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	m = a.index(min(a))
	c = 0
	for i in range(n):
		if i != m:
			while a[i] + a[m] <= k:
				a[i] += a[m]
				c += 1
	print(c)


t = int(input())
for testix in range(t):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	pin = min(l)
	out = 0
	for m in l:
		out += (k - m) // pin
	print(out - (k - pin) // pin)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	m = min(a)
	s = 0
	for e in a:
		s += (k - e) // m
	print(s - (k - m) // m)


T = int(input())
for _ in range(T):
	(n, k) = list(map(int, input().split()))
	a = list(map(int, input().split()))
	a = sorted(a)
	v = a[0]
	ans = 0
	for i in range(1, n):
		ans += (k - a[i]) // v
	print(ans)


import os
from io import BytesIO, IOBase
import sys
from collections import defaultdict, deque, Counter
from bisect import *
import sys

def main():
	for t in range(int(input())):
		(n, k) = map(int, input().split())
		a = list(map(int, input().split()))
		b = 0
		a.sort()
		for i in range(n):
			if a[i] < k:
				for j in range(n):
					if i == j:
						continue
					if a[j] + a[i] <= k:
						c = (k - a[j]) // a[i]
						a[j] = a[j] + c * a[i]
						b += c
		print(b)
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
main()


for _ in range(int(input())):
	(n, k) = input().split()
	n = int(n)
	k = int(k)
	l = [int(i) for i in input().split()]
	l.sort()
	a = l[0]
	count = 0
	for r in range(1, n):
		b = (k - l[r]) // a
		count += b
	print(count)


for i in range(int(input())):
	(n, k) = map(int, input().split(' '))
	nums = list(map(int, input().split(' ')))
	nums.sort()
	c = 0
	for j in range(1, len(nums)):
		c += (k - nums[j]) // nums[0]
	print(c)


def solve(n, arr, k):
	arr = sorted(arr)
	count = 0
	for j in range(1, n):
		count += (k - arr[j]) // arr[0]
	return count
t = int(input())
for i in range(t):
	_ = input().split()
	(n, k) = (int(_[0]), int(_[1]))
	x = input().split()
	arr = list(map(int, x))
	print(solve(n, arr, k))


t = int(input())
for _ in range(t):
	(a, b) = map(int, input().split())
	l = list(map(int, input().split()))
	l.sort()
	sum = 0
	for i in range(1, a):
		if b - l[i] > 0:
			sum += (b - l[i]) // l[0]
	print(sum)


for ad in range(int(input())):
	(n, k) = list(map(int, input().split()))
	l = list(map(int, input().split()))
	l.sort()
	x = l[0]
	ans = 0
	for i in range(n - 1, 0, -1):
		y = (k - l[i]) / x
		ans += int(y)
	print(ans)


from sys import stdin, stdout
from collections import Counter
from itertools import permutations
import bisect
import math
I = lambda : map(int, stdin.readline().split())
I1 = lambda : stdin.readline()
for _ in range(int(I1())):
	(n, k) = I()
	a = list(I())
	m = min(a)
	ind = a.index(m)
	c = 0
	for i in range(n):
		if ind == i:
			continue
		c += (k - a[i]) // m
	print(c)


def calc(n, k, a):
	a.sort()
	count = 0
	val = a[0]
	for i in range(1, n):
		count += max((k - a[i]) // val, 0)
	return count
t = int(input())
for i in range(t):
	(n, k) = list(map(int, input().split()))
	a = list(map(int, input().split()))
	print(calc(n, k, a))


import sys, math
input = lambda : sys.stdin.readline().rstrip()

def gcd(n, f):
	if n == 0 or f == 0:
		return max(n, f)
	if n > f:
		return gcd(n % f, f)
	else:
		return gcd(f % n, n)

def division_with_remainder_up(pp, ppp):
	return (pp + ppp - 1) // ppp
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a = sorted(a)
	c = a[0]
	a = a[1:]
	ans = 0
	for i in a:
		ans += (k - i) // c
	print(ans)


import sys
sys.setrecursionlimit(1000000)
T = int(input())
for _ in range(T):
	(n, k) = (int(x) for x in input().split())
	a = [int(x) for x in input().split()]
	res = 0
	delta = min(a)
	for x in a:
		res += (k - x) // delta
	res -= (k - delta) // delta
	print(res)


for i in range(int(input())):
	(n, k) = map(int, input().split())
	A = list(map(int, input().split()))
	y = min(A)
	A.remove(y)
	x = 0
	for j in A:
		x += (k - j) // y
	print(x)


import sys
t = int(input())

def solve(n, k, a):
	a.sort()
	am = a[0]
	S = 0
	for i in range(n - 1):
		temp = k - a[i + 1]
		S += temp // am
	print(S)
for i in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	solve(n, k, a)


def answer(n, k, A):
	A.sort()
	mini = A[0]
	count = 0
	for i in range(1, n):
		if A[i] < k:
			x = (k - A[i]) // mini
			count += x
	return count
t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	print(answer(n, k, arr))


game = int(input())
for i in range(game):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	count = 0
	if k >= a[n - 1]:
		for i in range(1, n):
			count += (k - a[i]) // a[0]
	print(count)


t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	arr.sort()
	p = arr[0]
	sol = 0
	for i in range(1, n):
		while arr[i] + p <= k:
			sol += 1
			arr[i] += p
	print(sol)


from functools import lru_cache
from sys import stdin, stdout
import sys
from math import *
input = stdin.readline
for __ in range(int(input())):
	(n, k) = map(int, input().split())
	ar = list(map(int, input().split()))
	ar.sort()
	if ar[-1] > k:
		print(0)
	else:
		m = ar[0]
		ans = 0
		for i in range(1, n):
			ans += (k - ar[i]) // m
		print(ans)


def fun(arr, n, k):
	mini = min(arr)
	index = arr.index(mini)
	sum = 0
	x = 0
	for i in range(n):
		if arr[i] < k and index != i:
			x = (k - arr[i]) // mini
			if x * mini + arr[i] > k:
				x = x - 1
			sum = sum + x
	return sum
for i in range(0, int(input())):
	(n, k) = [int(x) for x in input().split()]
	arr = [int(x) for x in input().split()]
	print(fun(arr, n, k))


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	l = sorted(l)
	count = 0
	if l[0] > k:
		print(0)
	else:
		for i in range(1, n):
			if l[i] > k:
				break
			else:
				count += (k - l[i]) // l[0]
		print(count)


import sys
sys.setrecursionlimit(10000000)
mod = 10 ** 9 + 7
INF = float('inf')
from sys import stdin
readline = stdin.readline

def readInts():
	return list(map(int, readline().split()))

def readTuples():
	return tuple(map(int, readline().split()))

def I():
	return int(readline())
q = I()
for _ in range(q):
	(n, k) = readInts()
	A = sorted(readInts(), reverse=True)
	ans = 0
	minus = A[-1]
	for i in range(n - 1):
		ans += (k - A[i]) // minus
	print(ans)


t = int(input())
for _ in range(t):
	(n, k) = [int(x) for x in input().split()]
	a = [int(x) for x in input().split()]
	mn = 100000
	idx = -1
	for i in range(n):
		if a[i] < mn:
			mn = a[i]
			idx = i
	s = 0
	for i in range(idx):
		s += (k - a[i]) // mn
	for i in range(idx + 1, n):
		s += (k - a[i]) // mn
	print(s)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = [int(x) for x in input().split()]
	mn = min(a)
	x = a.index(mn)
	s = 0
	for i in range(n):
		if i != x:
			s += (k - a[i]) // mn
	print(s)


for i in range(int(input())):
	(n, k) = map(int, input().split(' '))
	l = sorted(map(int, input().split(' ')))
	sum = 0
	for i in range(1, n):
		sum = sum + (k - l[i]) // l[0]
	print(sum)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	m = a[0]
	a = a[1:]
	total = 0
	for b in a:
		total += (k - b) // m
	print(total)


def solution(l, k):
	l.sort()
	s = 0
	c = 0
	for i in range(1, n):
		s += (k - l[i]) // l[0]
	print(s)
for i in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	solution(l, k)


from sys import stdin

def get_int():
	return int(stdin.readline())

def get_str():
	return stdin.readline().strip()

def get_ints():
	return map(int, stdin.readline().strip().split())

def get_array():
	return list(map(int, stdin.readline().strip().split()))

def get_array2d(row):
	return [list(map(int, stdin.readline().strip().split())) for _ in range(row)]
T = get_int()
for _ in range(T):
	(N, K) = get_ints()
	A = get_array()
	(ans, minA) = (0, min(A))
	A.remove(minA)
	for a in A:
		ans += (K - a) // minA
	print(ans)


import sys

def input():
	return sys.stdin.readline().rstrip()
t = int(input())
for i in range(t):
	[n, k] = list(map(int, input().split()))
	arr = list(map(int, input().split()))
	min_value = min(arr)
	ans = 0
	min_visited = False
	for value in arr:
		if value == min_value and min_visited == False:
			min_visited = True
		else:
			ans += int((k - value) // min_value)
	print(ans)


t = int(input())
while t:
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	m = min(a)
	a.remove(m)
	ans = 0
	for x in range(n - 1):
		ans = ans + (k - a[x]) // m
	print(ans)
	t -= 1


import sys, os, io
input = sys.stdin.readline
T = int(input())
ans = [0] * T
for t in range(T):
	(n, k) = map(int, input().split())
	A = list(map(int, input().split()))
	amin = min(A)
	A.remove(amin)
	for a in A:
		ans[t] += (k - a) // amin
print(*ans, sep='\n')


def main(numbers, k):
	least_number = min(numbers)
	result = 0
	numbers.remove(least_number)
	for pile_count in numbers:
		result += (k - pile_count) // least_number
	return result
tt = int(input())
for _ in range(tt):
	(n, k) = map(int, input().split(' '))
	numbers = list(map(int, input().split(' ')))
	print(main(numbers, k))


from enum import *
from copy import *
from sys import *
from collections import *
from itertools import *
from functools import *
from math import *

def l2i(fr=None):
	return map_type_to_fr(int, fr)[0]

def i2i(fr=None):
	return l2i(fr)

def dbg(*args):
	print(*args, file=stderr)

def dbv(var_name):
	print(f'{var_name} = {eval(var_name)}', file=stderr)

def map_type_to_fr(t, fr):
	global GETLINE_OFFSET
	if fr is None:
		if RUNNING_ON_MY_PC:
			fr = TEST_INP[GETLINE_OFFSET].split()
			GETLINE_OFFSET += 1
		else:
			fr = input().split()
	return list(map(t, fr))

def mis(fr=None):
	return map_type_to_fr(int, fr)

def mbs(fr=None):
	return map_type_to_fr(bool, fr)

def gs(fr=None):
	return map_type_to_fr(str, fr)[0]
import os
import sysconfig
RUNNING_ON_MY_PC = os.name == 'nt' and platform == 'win32' and (sysconfig.get_platform() == 'win-amd64')
GETLINE_OFFSET = 0
TEST_INP = '3\n2 2\n1 1\n3 5\n1 2 3\n3 7\n3 2 2\n'.split('\n')

def my_r(x):
	c = ceil(x)
	if c - x > 0.5:
		return floor(x)
	return c
for t in range(i2i()):
	(n, k) = mis()
	a = mis()
	s = sorted(a)
	q = s[0]
	ans = 0
	for el in s[1:][::-1]:
		ans += (k - el) // q
	print(ans)


t = int(input())
for u in range(t):
	(n, k) = map(int, input().split())
	a = [int(i) for i in input().split()]
	m = min(a)
	ans = 0
	for i in a:
		ans += (k - i) // m
	ans -= (k - m) // m
	print(ans)


t = int(input())
for z in range(t):
	(n, k) = input().split()
	n = int(n)
	k = int(k)
	a = list(map(int, input().split()))
	a.sort()
	c = 0
	for j in range(1, n):
		r = k - a[j]
		d = int(r / a[0])
		c += d
	print(c)


import sys
import math
input = sys.stdin.readline

def algo(arr, n, k):
	mn = min(arr)
	ans = 0
	for i in arr:
		ans += (k - i) // mn
	return ans - (k - mn) // mn
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	res = algo(arr, n, k)
	print(res)


t = int(input())
for _ in range(t):
	(n, k) = [int(x) for x in input().split()]
	a = [int(x) for x in input().split()]
	if max(a) > k:
		ans = 0
	else:
		m = min(a)
		i = a.index(m)
		ans = 0
		for j in range(n):
			if j != i:
				ans += (k - a[j]) // m
	print(ans)


t = int(input())
while t > 0:
	(n, k) = [int(x) for x in input().split()]
	a = [int(x) for x in input().split()]
	a.sort()
	if a[0] < k:
		c = 0
		key = a[0]
		for i in range(1, n):
			if a[i] - key > k:
				break
			else:
				c += (k - a[i]) // key
		print(c)
	else:
		print(0)
	t = t - 1


import math
import collections
from sys import stdin, stdout, setrecursionlimit
from bisect import bisect_left as bsl
from bisect import bisect_right as bsr
import heapq as hq
setrecursionlimit(2 ** 20)
t = 1
t = int(stdin.readline())
for _ in range(t):
	(n, k) = list(map(int, stdin.readline().rstrip().split()))
	a = list(map(int, stdin.readline().rstrip().split()))
	b = []
	for i in a:
		b.append(k - i)
	ans = 0
	for i in range(n):
		la = 0
		for j in range(n):
			if j != i:
				la += b[j] // a[i]
		ans = max(la, ans)
	print(ans)


def solve(n, k, a):
	j = 0
	for i in range(1, n):
		if a[j] > a[i]:
			j = i
	cnt = sum(((k - a[i]) // a[j] for i in range(n) if i != j))
	return cnt
tests = int(input())
for test in range(tests):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	print(solve(n, k, a))


x = int(input())
ansl = []
for i in range(x):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	l.sort()
	add = l[0]
	count = 0
	for i in range(1, len(l)):
		while not l[i] + add > k:
			l[i] += add
			count += 1
	ansl.append(count)
for i in ansl:
	print(i)


import sys
import random
from fractions import Fraction
from math import *
from decimal import *

def input():
	return sys.stdin.readline().strip()

def iinput():
	return int(input())

def finput():
	return float(input())

def tinput():
	return input().split()

def linput():
	return list(input())

def rinput():
	return map(int, tinput())

def fiinput():
	return map(float, tinput())

def rlinput():
	return list(map(int, input().split()))

def trinput():
	return tuple(rinput())

def srlinput():
	return sorted(list(map(int, input().split())))

def NOYES(fl):
	if fl:
		print('NO')
	else:
		print('YES')

def YESNO(fl):
	if fl:
		print('YES')
	else:
		print('NO')

def modst(a, s):
	res = 1
	while s:
		if s % 2:
			res = res * a % 998244353
		a *= a
		a = a % 998244353
		s //= 2
	return res

def main():
	(n, k) = rinput()
	q = srlinput()
	res = 0
	for i in range(1, n):
		res += (k - q[i]) // q[0]
	print(res)
for i in range(iinput()):
	main()


for t in range(int(input())):
	(n, k) = input().split()
	n = int(n)
	k = int(k)
	arr = [int(x) for x in input().split()]
	arr.sort()
	ans = 0
	for i in range(1, len(arr)):
		ans += int(abs(k - arr[i]) / arr[0])
	print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	res = 0
	a.sort()
	m = a[0]
	for i in range(1, n):
		res += (k - a[i]) // m
	print(res)


import sys

def input():
	return sys.stdin.readline().strip()

def list2d(a, b, c):
	return [[c for j in range(b)] for i in range(a)]

def list3d(a, b, c, d):
	return [[[d for k in range(c)] for j in range(b)] for i in range(a)]

def list4d(a, b, c, d, e):
	return [[[[e for l in range(d)] for k in range(c)] for j in range(b)] for i in range(a)]

def ceil(x, y=1):
	return int(-(-x // y))

def INT():
	return int(input())

def MAP():
	return map(int, input().split())

def LIST(N=None):
	return list(MAP()) if N is None else [INT() for i in range(N)]

def Yes():
	print('Yes')

def No():
	print('No')

def YES():
	print('YES')

def NO():
	print('NO')
INF = 10 ** 19
MOD = 10 ** 9 + 7
EPS = 10 ** (-10)
for _ in range(INT()):
	(N, K) = MAP()
	A = LIST()
	mn = min(A)
	A.pop(A.index(mn))
	N -= 1
	ans = 0
	for a in A:
		ans += (K - a) // mn
	print(ans)


from sys import stdin
N = int(stdin.readline())
for case in range(N):
	(n, k) = map(int, stdin.readline().split())
	array = list(map(int, stdin.readline().split()))
	mins = min(array)
	difarray = [(k - array[i]) // mins for i in range(n)]
	ans = sum(difarray) - (k - mins) // mins
	print(ans)


import sys
input = sys.stdin.readline
t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	L = list(map(int, input().split()))
	L.sort()
	count = 0
	for i in range(len(L) - 1):
		count += (k - L[i + 1]) // L[0]
	print(count)


import math, string, itertools, fractions, heapq, collections, re, array, bisect, sys, copy, functools
inf = 10 ** 20
eps = 1.0 / 10 ** 10
mod = 10 ** 9 + 7
mod2 = 998244353
dd = [(-1, 0), (0, 1), (1, 0), (0, -1)]
ddn = [(-1, 0), (-1, 1), (0, 1), (1, 1), (1, 0), (1, -1), (0, -1), (-1, -1)]

def LI():
	return list(map(int, sys.stdin.readline().split()))

def LLI():
	return [list(map(int, l.split())) for l in sys.stdin.readlines()]

def LI_():
	return [int(x) - 1 for x in sys.stdin.readline().split()]

def LF():
	return [float(x) for x in sys.stdin.readline().split()]

def LS():
	return sys.stdin.readline().split()

def I():
	return int(sys.stdin.readline())

def F():
	return float(sys.stdin.readline())

def S():
	return input()

def pf(s):
	return print(s, flush=True)

def pe(s):
	return print(str(s), file=sys.stderr)

def JA(a, sep):
	return sep.join(map(str, a))

def JAA(a, s, t):
	return s.join((t.join(map(str, b)) for b in a))

def IF(c, t, f):
	return t if c else f

def YES(c):
	return IF(c, 'YES', 'NO')

def Yes(c):
	return IF(c, 'Yes', 'No')

def main():
	t = I()
	rr = []
	for _ in range(t):
		(n, k) = LI()
		a = LI()
		a.sort()
		m = a[0]
		r = 0
		for c in a[1:]:
			r += (k - c) // m
		rr.append(r)
	return JA(rr, '\n')
print(main())


for _ in range(int(input())):
	k = list(map(int, input().split()))[1]
	candies = list(map(int, input().split()))
	candy_to_add = min(candies)
	(aux, ans) = (candies.index(candy_to_add), 0)
	for i in range(len(candies)):
		if i == aux:
			continue
		ans += (k - candies[i]) // candy_to_add
	print(ans)


t = int(input())
for i in range(t):
	(n, k) = [int(l) for l in input().split()]
	arr = [int(p) for p in input().split()]
	elem = min(arr)
	arr.remove(elem)
	counter = 0
	for j in range(len(arr)):
		counter = counter + (k - arr[j]) // elem
	print(counter)


cases = int(input())
while cases:
	cases -= 1
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	arr.sort()
	mn = arr.pop(0)
	ans = sum(((k - i) // mn for i in arr))
	print(ans)


T = input()
T = int(T)

def solve(n, k, arr):
	seed = min(arr)
	arr.remove(seed)
	ans = 0
	for i in range(n - 1):
		ans += (k - arr[i]) // seed
	print(ans)
for i in range(T):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	solve(n, k, arr)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = [int(x) for x in input().split()]
	a.sort(reverse=True)
	s = 0
	x = a[-1]
	for i in range(n - 1):
		s = s + (k - a[i]) // x
	print(s)


import math
t = int(input())
while t:
	t -= 1
	(n, k) = map(int, input().split())
	a = sorted(list(map(int, input().split())))
	ad = a[0]
	ans = 0
	for i in range(1, n):
		if a[i] < k:
			tem = k - a[i]
			tem1 = math.floor(tem / ad)
			ans += tem1
	print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	mins = min(a)
	pos = 0
	for i in range(len(a)):
		if mins == a[i]:
			pos = i
			break
	count = 0
	for j in range(len(a)):
		if j != pos:
			count += (k - a[j]) // mins
	print(count)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = [int(i) for i in input().split()]
	result = 0
	minimum_i = 0
	mini = 10 ** 5
	for i in range(len(a)):
		if a[i] < mini:
			mini = a[i]
			minimum_i = i
	for i in range(len(a)):
		if i != minimum_i:
			result += (k - a[i]) // mini
	print(result)


for _ in range(int(input())):
	(n, m) = map(int, input().split())
	a = list(map(int, input().split()))
	s = min(a)
	index = a.index(s)
	total = 0
	for j in range(0, n):
		if j != index:
			total += abs(a[j] - m) // s
	print(total)


num = int(input())
for cnt in range(num):
	(n, k) = map(int, input().split())
	ans = 0
	a = [int(x) for x in input().split()]
	a.sort()
	for i in range(1, n):
		ans += (k - a[i]) // a[0]
	print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	(count, mn) = (0, min(l))
	for el in l:
		count += (k - el) // mn
	print(count - (k - mn) // mn)


import sys
t = int(sys.stdin.readline().strip())
for i in range(t):
	(n, k) = map(int, sys.stdin.readline().split())
	line = list(map(int, sys.stdin.readline().split()))
	total = 0
	line.sort()
	while True:
		y = False
		for j in range(1, n):
			if line[j] + line[0] <= k:
				line[j] += line[0]
				y = True
				total += 1
		if not y:
			break
	print(total)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = [int(i) for i in input().split()]
	b = min(a)
	res = 0
	for i in range(n):
		if i != a.index(b):
			res += (k - a[i]) // b
	print(res)


for _ in range(int(input())):
	(n, k) = list(map(int, input().split()))
	lis = list(map(int, input().split()))
	lis = sorted(lis)
	q = lis[0]
	c = 0
	for i in range(1, n):
		w = abs(lis[i] - k)
		pp = w // q
		c += pp
	print(c)


from sys import stdin
input = stdin.buffer.readline
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	(*a,) = map(int, input().split())
	a.sort()
	res = 0
	for i in a[1:]:
		res += (k - i) // a[0]
	print(res)


def main():
	T = int(input())
	for _ in range(T):
		(n, k) = map(int, input().split())
		a = list(map(int, input().split()))
		m = total = 0
		for i in range(n):
			if a[i] < a[m]:
				m = i
		for j in range(n):
			if j == m:
				continue
			diff = k - a[j]
			total += diff // a[m]
		print(total)
main()


def solve():
	(n, k) = map(int, input().split())
	ls = sorted(list(map(int, input().split())))
	ans = 0
	for i in range(1, n):
		if ls[i] <= k:
			ans += (k - ls[i]) // ls[0]
	print(ans)
T = int(input())
for _ in range(T):
	solve()


T = int(input())
for I in range(T):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	mi = a[0]
	id = 0
	for i in range(n):
		if mi > a[i]:
			mi = a[i]
			id = i
	tot = 0
	for i in range(n):
		if i != id:
			tot += (k - a[i]) // mi
	print(tot)


import math
import random
import heapq, bisect
import sys
from collections import deque, defaultdict
from fractions import Fraction
import sys
import threading
from collections import defaultdict
mod = 10 ** 9 + 7
mod1 = 998244353
import os
import sys
from io import BytesIO, IOBase
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')

class TreeNode:

	def __init__(self, k, v):
		self.key = k
		self.value = v
		self.left = None
		self.right = None
		self.parent = None
		self.height = 1
		self.num_left = 1
		self.num_total = 1

class AvlTree:

	def __init__(self):
		self._tree = None

	def add(self, k, v):
		if not self._tree:
			self._tree = TreeNode(k, v)
			return
		node = self._add(k, v)
		if node:
			self._rebalance(node)

	def _add(self, k, v):
		node = self._tree
		while node:
			if k < node.key:
				if node.left:
					node = node.left
				else:
					node.left = TreeNode(k, v)
					node.left.parent = node
					return node.left
			elif node.key < k:
				if node.right:
					node = node.right
				else:
					node.right = TreeNode(k, v)
					node.right.parent = node
					return node.right
			else:
				node.value = v
				return

	@staticmethod
	def get_height(x):
		return x.height if x else 0

	@staticmethod
	def get_num_total(x):
		return x.num_total if x else 0

	def _rebalance(self, node):
		n = node
		while n:
			lh = self.get_height(n.left)
			rh = self.get_height(n.right)
			n.height = max(lh, rh) + 1
			balance_factor = lh - rh
			n.num_total = 1 + self.get_num_total(n.left) + self.get_num_total(n.right)
			n.num_left = 1 + self.get_num_total(n.left)
			if balance_factor > 1:
				if self.get_height(n.left.left) < self.get_height(n.left.right):
					self._rotate_left(n.left)
				self._rotate_right(n)
			elif balance_factor < -1:
				if self.get_height(n.right.right) < self.get_height(n.right.left):
					self._rotate_right(n.right)
				self._rotate_left(n)
			else:
				n = n.parent

	def _remove_one(self, node):
		replacement = node.left or node.right
		if node.parent:
			if AvlTree._is_left(node):
				node.parent.left = replacement
			else:
				node.parent.right = replacement
			replacement.parent = node.parent
			node.parent = None
		else:
			self._tree = replacement
			replacement.parent = None
		node.left = None
		node.right = None
		node.parent = None
		self._rebalance(replacement)

	def _remove_leaf(self, node):
		if node.parent:
			if AvlTree._is_left(node):
				node.parent.left = None
			else:
				node.parent.right = None
			self._rebalance(node.parent)
		else:
			self._tree = None
		node.parent = None
		node.left = None
		node.right = None

	def remove(self, k):
		node = self._get_node(k)
		if not node:
			return
		if AvlTree._is_leaf(node):
			self._remove_leaf(node)
			return
		if node.left and node.right:
			nxt = AvlTree._get_next(node)
			node.key = nxt.key
			node.value = nxt.value
			if self._is_leaf(nxt):
				self._remove_leaf(nxt)
			else:
				self._remove_one(nxt)
			self._rebalance(node)
		else:
			self._remove_one(node)

	def get(self, k):
		node = self._get_node(k)
		return node.value if node else -1

	def _get_node(self, k):
		if not self._tree:
			return None
		node = self._tree
		while node:
			if k < node.key:
				node = node.left
			elif node.key < k:
				node = node.right
			else:
				return node
		return None

	def get_at(self, pos):
		x = pos + 1
		node = self._tree
		while node:
			if x < node.num_left:
				node = node.left
			elif node.num_left < x:
				x -= node.num_left
				node = node.right
			else:
				return (node.key, node.value)
		raise IndexError('Out of ranges')

	@staticmethod
	def _is_left(node):
		return node.parent.left and node.parent.left == node

	@staticmethod
	def _is_leaf(node):
		return node.left is None and node.right is None

	def _rotate_right(self, node):
		if not node.parent:
			self._tree = node.left
			node.left.parent = None
		elif AvlTree._is_left(node):
			node.parent.left = node.left
			node.left.parent = node.parent
		else:
			node.parent.right = node.left
			node.left.parent = node.parent
		bk = node.left.right
		node.left.right = node
		node.parent = node.left
		node.left = bk
		if bk:
			bk.parent = node
		node.height = max(self.get_height(node.left), self.get_height(node.right)) + 1
		node.num_total = 1 + self.get_num_total(node.left) + self.get_num_total(node.right)
		node.num_left = 1 + self.get_num_total(node.left)

	def _rotate_left(self, node):
		if not node.parent:
			self._tree = node.right
			node.right.parent = None
		elif AvlTree._is_left(node):
			node.parent.left = node.right
			node.right.parent = node.parent
		else:
			node.parent.right = node.right
			node.right.parent = node.parent
		bk = node.right.left
		node.right.left = node
		node.parent = node.right
		node.right = bk
		if bk:
			bk.parent = node
		node.height = max(self.get_height(node.left), self.get_height(node.right)) + 1
		node.num_total = 1 + self.get_num_total(node.left) + self.get_num_total(node.right)
		node.num_left = 1 + self.get_num_total(node.left)

	@staticmethod
	def _get_next(node):
		if not node.right:
			return node.parent
		n = node.right
		while n.left:
			n = n.left
		return n

class SegmentTree1:

	def __init__(self, data, default=2 ** 30, func=lambda a, b: min(a, b)):
		self._default = default
		self._func = func
		self._len = len(data)
		self._size = _size = 1 << (self._len - 1).bit_length()
		self.data = [default] * (2 * _size)
		self.data[_size:_size + self._len] = data
		for i in reversed(range(_size)):
			self.data[i] = func(self.data[i + i], self.data[i + i + 1])

	def __delitem__(self, idx):
		self[idx] = self._default

	def __getitem__(self, idx):
		return self.data[idx + self._size]

	def __setitem__(self, idx, value):
		idx += self._size
		self.data[idx] = value
		idx >>= 1
		while idx:
			self.data[idx] = self._func(self.data[2 * idx], self.data[2 * idx + 1])
			idx >>= 1

	def __len__(self):
		return self._len

	def query(self, start, stop):
		if start == stop:
			return self.__getitem__(start)
		stop += 1
		start += self._size
		stop += self._size
		res = self._default
		while start < stop:
			if start & 1:
				res = self._func(res, self.data[start])
				start += 1
			if stop & 1:
				stop -= 1
				res = self._func(res, self.data[stop])
			start >>= 1
			stop >>= 1
		return res

	def __repr__(self):
		return 'SegmentTree({0})'.format(self.data)

class SegmentTree:

	def __init__(self, data, default=0, func=lambda a, b: max(a, b)):
		self._default = default
		self._func = func
		self._len = len(data)
		self._size = _size = 1 << (self._len - 1).bit_length()
		self.data = [default] * (2 * _size)
		self.data[_size:_size + self._len] = data
		for i in reversed(range(_size)):
			self.data[i] = func(self.data[i + i], self.data[i + i + 1])

	def __delitem__(self, idx):
		self[idx] = self._default

	def __getitem__(self, idx):
		return self.data[idx + self._size]

	def __setitem__(self, idx, value):
		idx += self._size
		self.data[idx] = value
		idx >>= 1
		while idx:
			self.data[idx] = self._func(self.data[2 * idx], self.data[2 * idx + 1])
			idx >>= 1

	def __len__(self):
		return self._len

	def query(self, start, stop):
		if start == stop:
			return self.__getitem__(start)
		stop += 1
		start += self._size
		stop += self._size
		res = self._default
		while start < stop:
			if start & 1:
				res = self._func(res, self.data[start])
				start += 1
			if stop & 1:
				stop -= 1
				res = self._func(res, self.data[stop])
			start >>= 1
			stop >>= 1
		return res

	def __repr__(self):
		return 'SegmentTree({0})'.format(self.data)

class Factorial:

	def __init__(self, MOD):
		self.MOD = MOD
		self.factorials = [1, 1]
		self.invModulos = [0, 1]
		self.invFactorial_ = [1, 1]

	def calc(self, n):
		if n <= -1:
			print('Invalid argument to calculate n!')
			print('n must be non-negative value. But the argument was ' + str(n))
			exit()
		if n < len(self.factorials):
			return self.factorials[n]
		nextArr = [0] * (n + 1 - len(self.factorials))
		initialI = len(self.factorials)
		prev = self.factorials[-1]
		m = self.MOD
		for i in range(initialI, n + 1):
			prev = nextArr[i - initialI] = prev * i % m
		self.factorials += nextArr
		return self.factorials[n]

	def inv(self, n):
		if n <= -1:
			print('Invalid argument to calculate n^(-1)')
			print('n must be non-negative value. But the argument was ' + str(n))
			exit()
		p = self.MOD
		pi = n % p
		if pi < len(self.invModulos):
			return self.invModulos[pi]
		nextArr = [0] * (n + 1 - len(self.invModulos))
		initialI = len(self.invModulos)
		for i in range(initialI, min(p, n + 1)):
			next = -self.invModulos[p % i] * (p // i) % p
			self.invModulos.append(next)
		return self.invModulos[pi]

	def invFactorial(self, n):
		if n <= -1:
			print('Invalid argument to calculate (n^(-1))!')
			print('n must be non-negative value. But the argument was ' + str(n))
			exit()
		if n < len(self.invFactorial_):
			return self.invFactorial_[n]
		self.inv(n)
		nextArr = [0] * (n + 1 - len(self.invFactorial_))
		initialI = len(self.invFactorial_)
		prev = self.invFactorial_[-1]
		p = self.MOD
		for i in range(initialI, n + 1):
			prev = nextArr[i - initialI] = prev * self.invModulos[i % p] % p
		self.invFactorial_ += nextArr
		return self.invFactorial_[n]

class Combination:

	def __init__(self, MOD):
		self.MOD = MOD
		self.factorial = Factorial(MOD)

	def ncr(self, n, k):
		if k < 0 or n < k:
			return 0
		k = min(k, n - k)
		f = self.factorial
		return f.calc(n) * f.invFactorial(max(n - k, k)) * f.invFactorial(min(k, n - k)) % self.MOD

def powm(a, n, m):
	if a == 1 or n == 0:
		return 1
	if n % 2 == 0:
		s = powm(a, n // 2, m)
		return s * s % m
	else:
		return a * powm(a, n - 1, m) % m

def sort_list(list1, list2):
	zipped_pairs = zip(list2, list1)
	z = [x for (_, x) in sorted(zipped_pairs)]
	return z

def product(l):
	por = 1
	for i in range(len(l)):
		por *= l[i]
	return por

def binarySearchCount(arr, n, key):
	left = 0
	right = n - 1
	count = 0
	while left <= right:
		mid = int((right + left) / 2)
		if arr[mid] < key:
			count = mid + 1
			left = mid + 1
		else:
			right = mid - 1
	return count

def countdig(n):
	c = 0
	while n > 0:
		n //= 10
		c += 1
	return c

def binary(x, length):
	y = bin(x)[2:]
	return y if len(y) >= length else '0' * (length - len(y)) + y

def countGreater(arr, n, k):
	l = 0
	r = n - 1
	leftGreater = n
	while l <= r:
		m = int(l + (r - l) / 2)
		if arr[m] > k:
			leftGreater = m
			r = m - 1
		else:
			l = m + 1
	return n - leftGreater

class TrieNode:

	def __init__(self):
		self.children = [None] * 26
		self.isEndOfWord = False

class Trie:

	def __init__(self):
		self.root = self.getNode()

	def getNode(self):
		return TrieNode()

	def _charToIndex(self, ch):
		return ord(ch) - ord('a')

	def insert(self, key):
		pCrawl = self.root
		length = len(key)
		for level in range(length):
			index = self._charToIndex(key[level])
			if not pCrawl.children[index]:
				pCrawl.children[index] = self.getNode()
			pCrawl = pCrawl.children[index]
		pCrawl.isEndOfWord = True

	def search(self, key):
		pCrawl = self.root
		length = len(key)
		for level in range(length):
			index = self._charToIndex(key[level])
			if not pCrawl.children[index]:
				return False
			pCrawl = pCrawl.children[index]
		return pCrawl != None and pCrawl.isEndOfWord

class Node:

	def __init__(self, data):
		self.data = data
		self.count = 0
		self.left = None
		self.right = None

class BinaryTrie:

	def __init__(self):
		self.root = Node(0)

	def insert(self, pre_xor):
		self.temp = self.root
		for i in range(31, -1, -1):
			val = pre_xor & 1 << i
			if val:
				if not self.temp.right:
					self.temp.right = Node(0)
				self.temp = self.temp.right
				self.temp.count += 1
			if not val:
				if not self.temp.left:
					self.temp.left = Node(0)
				self.temp = self.temp.left
				self.temp.count += 1
		self.temp.data = pre_xor

	def query(self, xor):
		self.temp = self.root
		for i in range(31, -1, -1):
			val = xor & 1 << i
			if not val:
				if self.temp.left and self.temp.left.count > 0:
					self.temp = self.temp.left
				elif self.temp.right:
					self.temp = self.temp.right
			elif self.temp.right and self.temp.right.count > 0:
				self.temp = self.temp.right
			elif self.temp.left:
				self.temp = self.temp.left
			self.temp.count -= 1
		return xor ^ self.temp.data
for ik in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	l.sort()
	ans = 0
	for i in range(1, n):
		ans += (-l[i] + k) // l[0]
	print(ans)


for dsds in range(int(input())):
	(n, k) = map(int, input().split())
	s = list(map(int, input().split()))
	m = 10 ** 4 + 1
	v = 0
	for i in range(n):
		if s[i] < m:
			m = s[i]
			v = i
	q = 0
	for i in range(n):
		if i != v:
			q += (k - s[i]) // m
	print(q)


for j in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	m = min(l)
	l.remove(m)
	ans = 0
	for ele in l:
		ans += (k - ele) // m
	print(ans)


for aww in range(int(input())):
	(a, b) = [*map(int, input().split())]
	c = [*map(int, input().split())]
	c.sort()
	d = 0
	for i in c[1:]:
		d += (b - i) // c[0]
	print(d)


import math

def main():
	t = int(input())
	vals = []
	for t_ in range(t):
		(n, k) = list(map(int, input().split(' ')))
		arr = list(map(int, input().split(' ')))
		min_ = min(arr)
		min_ind = arr.index(min_)
		ct = 0
		for i in range(len(arr)):
			if i == min_ind:
				continue
			ct += (k - arr[i]) // min_
		vals.append(ct)
	for val in vals:
		print(val)
main()


def main(n, k, a):
	res = 0
	for i in range(1, n):
		res += (k - a[i]) // a[0]
	return res
for i in range(int(input())):
	(n, k) = map(int, input().split())
	a = sorted(map(int, input().split()))
	print(main(n, k, a))


def solve():
	(n, k) = [int(x) for x in input().split(' ')]
	data = [int(x) for x in input().split(' ')]
	_min = min(data)
	min_i = data.index(_min)
	result = 0
	for i in range(n):
		if i == min_i or data[i] >= k:
			continue
		result += (k - data[i]) // _min
	print(result)
for _ in range(int(input())):
	solve()


from sys import stdin, stdout
import math, sys
from itertools import permutations, combinations
from collections import defaultdict, deque, OrderedDict, Counter
from os import path
import bisect as bi
import heapq
mod = 10 ** 9 + 7

def yes():
	print('YES')

def no():
	print('NO')
if path.exists('input.txt'):
	sys.stdin = open('input.txt', 'r')
	sys.stdout = open('output.txt', 'w')

	def inp():
		return int(input())

	def minp():
		return map(int, input().split())
else:

	def inp():
		return int(stdin.readline())

	def minp():
		return map(int, stdin.readline().split())
for _ in range(inp()):
	(n, k) = minp()
	a = list(minp())
	a.sort()
	total = 0
	for i in range(1, n):
		total += (k - a[i]) // a[0]
	print(total)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	loc = arr.index(min(arr))
	ans = 0
	for i in range(n):
		if loc != i:
			ans += (k - arr[i]) // arr[loc]
	print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	lis = sorted(map(int, input().split()))
	a = lis[0]
	ans = 0
	for i in range(1, n):
		tmp = max(0, k - lis[i])
		ans += tmp // a
		lis[i] += tmp // a * a
	lis[0] = 10000000000000000
	lis.sort()
	tmp = max(0, k - a)
	ans += tmp // lis[0]
	print(ans)


t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	f = a[0]
	c = 0
	for j in range(1, len(a)):
		val = (k - a[j]) // f
		c += val
	print(c)


tc = int(input())
for _ in range(tc):
	(n, k) = map(int, input().split())
	l = sorted(list(map(int, input().split())))
	count = 0
	i = 0
	j = 1
	while j <= len(l) - 1:
		while l[i] + l[j] <= k:
			l[j] += l[i]
			count += 1
		j += 1
	print(count)


t = int(input())
for i in range(0, t):
	(a, b) = map(int, input().split())
	arr = list(map(int, input().strip().split()))[:a]
	y = min(arr)
	ct = 0
	for i in range(0, a):
		z = b - arr[i]
		ct = ct + int(z / y)
	xx = b - y
	zz = int(xx / y)
	ct = ct - zz
	print(ct)


import heapq

def start():
	T = int(input())
	for _ in range(T):
		(n, k) = input().split()
		(n, k) = (int(n), int(k))
		nums = list((int(x) for x in input().split()))
		count = 0
		heapq.heapify(nums)
		while True:
			a = heapq.heappop(nums)
			b = heapq.heappop(nums)
			if a + b > k:
				break
			c = (k - b) // a
			count += c
			b += c * a
			heapq.heappush(nums, b)
			heapq.heappush(nums, a)
		print(count)
start()


for x in range(int(input())):
	(n, k) = map(int, input().split())
	a = [int(x) for x in input().split()][:n]
	a = sorted(a)
	c = a[0]
	d = 0
	for x in range(1, n):
		i = k - a[x]
		d = d + i // c
	print(d)


t = int(input())
while t:
	(n, k) = map(int, input().split())
	a = list(map(int, input().split(' ')))
	c = 0
	mind = a.index(min(a))
	for i in range(0, len(a)):
		if i != mind:
			c += (k - a[i]) // min(a)
		else:
			continue
	print(c)
	c = 0
	t -= 1


import sys
import math
input = sys.stdin.readline
t = int(input())
for _ in range(t):
	(n, k) = list(map(int, input().split()))
	arr = list(map(int, input().split()))
	arr.sort()
	x = arr[0]
	ans = 0
	for i in range(1, len(arr)):
		ans += (k - arr[i]) // x
	print(ans)


def tinh_so(b, c, z):
	sum = 0
	z.sort()
	for i in z:
		x = (int(c) - i) // min(z)
		y = (int(c) - z[0]) // min(z)
		sum += x
	return sum - y
a = int(input())
for i in range(1, a + 1):
	(b, c) = input().split()
	lst = [int(i) for i in input().split()]
	print(tinh_so(b, c, lst))


import sys
from collections import defaultdict as dd
from collections import Counter as cc
from queue import Queue
import math
import itertools
try:
	sys.stdin = open('input.txt', 'r')
	sys.stdout = open('output.txt', 'w')
except:
	pass
input = lambda : sys.stdin.buffer.readline().rstrip()
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = sorted(list(map(int, input().split())))
	q = a[0]
	t = 0
	for i in range(1, n):
		t += (k - a[i]) // q
	print(t)


def main():
	t = int(input())
	for _ in range(t):
		(n, k) = map(int, input().split())
		s = list(map(int, input().split()))
		s.sort()
		if s[0] >= k:
			print(0)
		else:
			cnt = 0
			for i in range(1, n):
				if s[i] < k:
					cnt += (k - s[i]) // s[0]
				else:
					break
			print(cnt)
main()


from sys import stdin
input = stdin.readline

def solve():
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	mn = min(a)
	s = sum(((k - i) // mn for i in a))
	s -= (k - mn) // mn
	print(s)
t = int(input())
for _ in range(t):
	solve()


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	inp = list(map(int, input().split()))
	inp = sorted(inp)
	mi = inp[0]
	ma = inp[n - 1]
	cnt = 0
	for i in range(1, n):
		temp = k - inp[i]
		cnt += temp // mi
	print(cnt)


import math
import sys
import itertools
import fractions
wtf = sys.stdin.read()
wtf = wtf.strip().split('\n')
for t in [wtf[i:i + 2] for i in range(1, len(wtf), 2)]:
	(n, k) = map(int, t[0].split())
	A = sorted(map(int, t[1].split()))
	ans = 0
	for i in range(1, n):
		if A[i] < k:
			ans += (k - A[i]) // A[0]
	print(ans)


import random

def gcd(a, b):
	if a == 0:
		return b
	return gcd(b % a, a)

def lcm(a, b):
	return a * b / gcd(a, b)
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	c = 0
	for i in range(1, n):
		c += (-min(a[i], k) + k) // a[0]
	print(c)


def getCount(arr):
	minpos = arr.index(min(arr))
	minVal = arr[minpos]
	count = 0
	for i in range(n):
		if i != minpos:
			if arr[i] > k:
				return 0
			count += (k - arr[i]) // minVal
	return count
testCases = input()
for i in range(int(testCases)):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	ans = getCount(arr)
	print(ans)


TEST_CASES = int(input())
for y in range(TEST_CASES):
	NK = input().split()
	LSTV = input().split()
	NK = [int(x) for x in NK]
	LSTV = [int(x) for x in LSTV]
	N = NK[0]
	K = NK[1]
	ADDER = min(LSTV)
	ADDER_INDEX = LSTV.index(ADDER)
	OPRS = 0
	for x in range(len(LSTV)):
		if x != ADDER_INDEX:
			OPRS += (K - LSTV[x]) // ADDER
	print(OPRS)


def test_case():
	(n, k) = map(int, input().split())
	piles = list(map(int, input().split()))
	i = None
	for p in piles:
		if not i or p < i:
			i = p
	count = 0
	piles.remove(i)
	for p in piles:
		count += (k - p) // i
	return count

def main():
	cases = int(input())
	for _ in range(cases):
		print(test_case())
main()


from sys import stdin, stdout
from math import gcd, sqrt, factorial, pi, inf
from collections import deque, defaultdict
input = stdin.readline
R = lambda : map(int, input().split())
I = lambda : int(input())
S = lambda : input().rstrip('\n')
L = lambda : list(R())
P = lambda x: stdout.write(x)
lcm = lambda x, y: x * y // gcd(x, y)
hg = lambda x, y: (y + x - 1) // x * x
pw = lambda x: 1 if x == 1 else 1 + pw(x // 2)
chk = lambda x: chk(x // 2) if not x % 2 else True if x == 1 else False
sm = lambda x: (x ** 2 + x) // 2
N = 10 ** 9 + 7
for _ in range(I()):
	(n, k) = R()
	a = sorted(R())
	ans = 0
	for i in a[1:]:
		ans += (k - i) // a[0]
	print(ans)


numLines = int(input(''))
user = []
for i in range(0, numLines):
	firstLine = input('')
	secondLine = input('')
	nK = firstLine.split(' ')
	k = int(nK[1])
	allNums = list(secondLine.split(' '))
	for i in range(0, len(allNums)):
		allNums[i] = int(allNums[i])
	smallestNum = min(allNums)
	allNums.remove(smallestNum)
	spellsCast = 0
	for i in range(0, len(allNums)):
		if allNums[i] + smallestNum <= k:
			spellsCast = spellsCast + int((k - allNums[i]) / smallestNum)
			allNums[i] = allNums[i] + int((k - allNums[i]) / smallestNum) * smallestNum
	secondSmallestNum = min(allNums)
	if smallestNum + secondSmallestNum <= k:
		spellsCast = spellsCast + int((k - smallestNum) / secondSmallestNum)
	print(spellsCast)


for i in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	sum = 0
	j = 1
	while j < n and a[j] < k:
		sum += (k - a[j]) // a[0]
		j += 1
	print(int(sum))


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	mn = min(a)
	x = a.index(mn)
	ans = 0
	for i in range(n):
		if i != x and a[i] < k:
			ans += (k - a[i]) // mn
	print(ans)


t = int(input())
for _ in range(t):
	(n, k) = (int(i) for i in input().split())
	a = [int(i) for i in input().split()]
	(res, mi) = (0, min(range(n), key=a.__getitem__))
	for i in range(n):
		if i != mi:
			res += (k - a[i]) // a[mi]
	print(res)


t = int(input())
for tc in range(t):
	line = input().split()
	(n, k) = (int(line[0]), int(line[1]))
	line = input().split()
	arr = []
	for i in range(n):
		arr.append(int(line[i]))
	diff = []
	min_ele = min(arr)
	count = 0
	min_index = arr.index(min_ele)
	for i in range(n):
		diff.append(k - arr[i])
		count += diff[i] // min_ele
	count -= diff[min_index] // min_ele
	print(count)


import math
for i in range(int(input())):
	(n, k) = map(int, input().split())
	t = list(map(int, input().split()))
	u = 0
	t.sort()
	for j in range(1, n):
		if t[j] < k:
			u += math.ceil(k - t[j]) // t[0]
	print(int(u))


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	s = sorted(l)
	fe = s[0]
	ans = 0
	for i in range(1, n):
		if s[i] <= k:
			ans = ans + (k - s[i]) // fe
	print(ans)


def keepPower(n, k, a):
	amin = min(a)
	foundMin = 0
	count = 0
	for i in range(len(a)):
		if a[i] == amin and foundMin == 0:
			foundMin = 1
			continue
		count += (k - a[i]) // amin
	return count
t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	print(keepPower(n, k, a))


t = int(input())
for case in range(t):
	inp = list(map(int, str.split(input(), ' ')))
	a = list(map(int, str.split(input(), ' ')))
	n = inp[0]
	k = inp[1]
	a.sort()
	ans = 0
	for i in range(1, n):
		ans += (k - a[i]) // a[0]
	print(ans)


T = int(input())
for i in range(T):
	(N, K) = map(int, input().split())
	A = sorted(list(map(int, input().split())))
	count = 0
	for i in range(1, len(A)):
		count += (K - A[i]) // A[0]
	print(count)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	minimum = min(arr)
	arr.remove(minimum)
	res = 0
	for num in arr:
		if num < k:
			res += (k - num) // minimum
	print(res)


n = int(input())
for i in range(n):
	(x, y) = map(int, input().split())
	list1 = list(map(int, input().split()))
	list1.sort(reverse=True)
	times = 0
	for j in range(x - 1):
		times = times + (y - list1[j]) // list1[x - 1]
	print(times)


import sys
from collections import defaultdict, Counter as CC
from math import sqrt, ceil, floor, log2
INF = float('inf')
MOD = 10 ** 9 + 7
read = lambda : [int(s) for s in sys.stdin.readline().split()]

def solve():
	(n, k) = read()
	a = read()
	a.sort()
	res = 0
	for i in range(1, n):
		res += max(0, k - a[i]) // a[0]
	print(res)
_ = 1
_ = int(input())
while _:
	solve()
	_ -= 1


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = sorted(list(map(int, input().split())))
	x = a[0]
	a.pop(0)
	ans = 0
	for i in range(n - 1):
		x1 = k - a[i]
		ans += x1 // x
	print(ans)


import sys, os.path
from collections import *
from copy import *
import math
mod = 10 ** 9 + 7
if os.path.exists('input.txt'):
	sys.stdin = open('input.txt', 'r')
	sys.stdout = open('output.txt', 'w')
for t in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	b = min(a)
	c = 0
	for i in range(1, n):
		while a[i] + b <= k:
			c += 1
			a[i] += b
	print(c)


for tc in range(int(input())):
	(n, k) = map(int, input().split())
	s = sorted(list(map(int, input().split())))
	ans = 0
	for i in s[1:]:
		ans += (k - i) // s[0]
	print(ans)


for h in range(int(input())):
	(n, k) = map(int, input().strip().split())
	arr = list(map(int, input().strip().split()))
	arr.sort()
	ans = 0
	for i in range(1, n):
		ans += max(0, (k - arr[i]) // arr[0])
	print(ans)


import math

def inp():
	return int(input())

def insr():
	s = input()
	return s

def inlt():
	return list(map(int, input().split()))

def inlts():
	return input().split()

def dig_sum(s):
	return sum([int(i) for i in s])

def solve(l, k):
	m = min(l)
	firstmin = True
	ans = 0
	for i in range(len(l)):
		if l[i] == m and firstmin == True:
			firstmin = False
			continue
		ans += (k - l[i]) // m
	return ans
r = inp()
for i in range(r):
	l2 = inlt()
	l = inlt()
	print(solve(l, l2[1]))


for i in range(int(input())):
	(n, k) = map(int, input().split())
	lst1 = map(int, input().split())
	lst = list(lst1)
	lst.sort()
	ans = 0
	for i in range(1, n):
		ans += int((k - lst[i]) / lst[0])
	print(ans)


T = int(input())
for t in range(T):
	(n, k) = [int(x) for x in input().strip().split()]
	piles = [int(x) for x in input().strip().split()]
	piles.sort()
	most = 0
	mi = min(piles)
	piles.remove(mi)
	for p in piles:
		most += int((k - p) / mi)
	print(most)


t = int(input())
for i in range(t):
	(totalLen, maxLim) = list(map(int, input().split()))
	totalInp = list(map(int, input().split()))
	lowNum = maxLim + 1
	pos = -1
	for i in range(len(totalInp)):
		if totalInp[i] < lowNum:
			lowNum = totalInp[i]
			pos = i
	co = 0
	for i in range(len(totalInp)):
		if i != pos:
			co += (maxLim - totalInp[i]) // lowNum
	print(co)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	ans = 0
	mn = min(arr)
	ind = arr.index(mn)
	for i in range(n):
		if i != ind and arr[i] <= k:
			ans += (k - arr[i]) // mn
	print(ans)


import math
t = int(input())
while t != 0:
	t -= 1
	(n, k) = map(int, input().split())
	ind = n
	su = 0
	li = list(map(int, input().split()))
	li.sort()
	x = li[0]
	for i in range(1, n):
		su += math.floor((k - li[i]) / x)
	print(su)


mod = 10 ** 9 + 7
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	arr.sort()
	count = 0
	for i in range(1, n):
		dif = k - arr[i]
		count += dif // arr[0]
		arr[i] = arr[i] + dif // arr[0] * arr[0]
	a = min(arr[1:])
	dif = k - arr[0]
	count += dif // a
	print(count)


import sys

def input():
	return sys.stdin.readline()[:-1]

def getInt():
	return int(input())

def getIntIter():
	return list(map(int, input().split()))

def getIntList():
	return list(getIntIter())

def flush():
	sys.stdout.flush()
for _ in range(getInt()):
	(n, k) = getIntIter()
	nums = getIntList()
	m = min(nums)
	ans = 0
	for num in nums:
		ans += (k - num) // m
	ans -= (k - m) // m
	print(ans)


from sys import stdin, stdout
st = lambda : list(stdin.readline().strip())
li = lambda : list(map(int, stdin.readline().split()))
mp = lambda : map(int, stdin.readline().split())
inp = lambda : int(stdin.readline())
pr = lambda n: stdout.write(str(n) + '\n')
mod = 1000000007
INF = float('inf')

def solve():
	(n, k) = mp()
	l = li()
	l.sort()
	ans = 0
	a = l[0]
	for i in range(1, n):
		if l[i] <= k:
			ans += (k - l[i]) // a
	pr(ans)
for _ in range(inp()):
	solve()


for _ in range(int(input())):
	(n, k) = list(map(int, input().split()))
	(*arr,) = list(map(int, input().split()))
	cnt = 0
	mn = min(arr)
	arr.remove(mn)
	for v in arr:
		cnt += (k - v) // mn
	print(cnt)


t = int(input())
for _ in range(t):
	(n, k) = [int(x) for x in input().split()]
	l = [int(x) for x in input().split()]
	ans = 0
	m = min(l)
	mi = l.index(m)
	for i in range(n):
		if i != mi:
			ans += max((k - l[i]) // m, 0)
	print(ans)


import sys

def rs():
	return sys.stdin.readline().rstrip()

def ri():
	return int(sys.stdin.readline())

def ria():
	return list(map(int, sys.stdin.readline().split()))

def ws(s):
	sys.stdout.write(s + '\n')

def wi(n):
	sys.stdout.write(str(n) + '\n')

def wia(a):
	sys.stdout.write(' '.join([str(x) for x in a]) + '\n')

def ceil(x, y=1):
	return int(-(-x // y))
import math
from collections import defaultdict
for _ in range(ri()):
	(n, k) = ria()
	l = ria()
	l.sort(reverse=True)
	x = l[-1]
	cnt = 0
	for i in range(n - 1):
		if l[i] < k:
			z = k - l[i]
			cnt = cnt + z // x
			l[i] = l[i] + z // x * x
	if l[-1] + min(l[:n - 1]) < k:
		cnt += 1
	wi(cnt)


for t in range(int(input())):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	count = 0
	if max(arr) > k:
		print(0)
		continue
	arr.sort(reverse=True)
	minim = arr[-1]
	for i in range(n - 1):
		diff = k - arr[i]
		count += int(diff / minim)
		arr[i] += minim * count
	minim = min(arr[:n - 1])
	diff = k - arr[-1]
	count += int(diff / minim)
	print(count)


import sys
import math
import itertools
import functools
import collections
import operator
import fileinput
import copy
ORDA = 97

def ii():
	return int(input())

def mi():
	return map(int, input().split())

def li():
	return [int(i) for i in input().split()]

def lcm(a, b):
	return abs(a * b) // math.gcd(a, b)

def revn(n):
	return str(n)[::-1]

def dd():
	return collections.defaultdict(int)

def ddl():
	return collections.defaultdict(list)

def sieve(n):
	if n < 2:
		return list()
	prime = [True for _ in range(n + 1)]
	p = 3
	while p * p <= n:
		if prime[p]:
			for i in range(p * 2, n + 1, p):
				prime[i] = False
		p += 2
	r = [2]
	for p in range(3, n + 1, 2):
		if prime[p]:
			r.append(p)
	return r

def divs(n, start=2):
	r = []
	for i in range(start, int(math.sqrt(n) + 1)):
		if n % i == 0:
			if n / i == i:
				r.append(i)
			else:
				r.extend([i, n // i])
	return r

def divn(n, primes):
	divs_number = 1
	for i in primes:
		if n == 1:
			return divs_number
		t = 1
		while n % i == 0:
			t += 1
			n //= i
		divs_number *= t

def prime(n):
	if n == 2:
		return True
	if n % 2 == 0 or n <= 1:
		return False
	sqr = int(math.sqrt(n)) + 1
	for d in range(3, sqr, 2):
		if n % d == 0:
			return False
	return True

def convn(number, base):
	new_number = 0
	while number > 0:
		new_number += number % base
		number //= base
	return new_number

def cdiv(n, k):
	return n // k + (n % k != 0)

def ispal(s):
	for i in range(len(s) // 2 + 1):
		if s[i] != s[-i - 1]:
			return False
	return True
for _ in range(ii()):
	(n, k) = mi()
	a = sorted(li())
	ans = 0
	for i in a[1:]:
		ans += (k - i) // a[0]
	print(ans)


t = int(input())
for ii in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	least = a[0]
	count = 0
	for i in range(1, n):
		count += (k - a[i]) // least
		a[i] += (k - a[i]) // least * least
	if n > 1:
		m = min(a[1:])
		while m + a[0] <= k:
			a[0] += m
			count += 1
	print(count)


for i in range(int(input())):
	(n, k) = map(int, input().split(' '))
	values = sorted(list(filter(lambda x: x < k, map(int, input().split(' ')))))
	count = 0
	for value in values[1:]:
		count += (k - value) // values[0]
	print(count)


import sys
sys.setrecursionlimit(10 ** 5)
int1 = lambda x: int(x) - 1
p2D = lambda x: print(*x, sep='\n')

def II():
	return int(sys.stdin.readline())

def MI():
	return map(int, sys.stdin.readline().split())

def LI():
	return list(map(int, sys.stdin.readline().split()))

def LLI(rows_number):
	return [LI() for _ in range(rows_number)]

def SI():
	return sys.stdin.readline()[:-1]
for _ in range(II()):
	(n, k) = MI()
	aa = LI()
	aa.sort()
	ans = 0
	for a in aa[1:]:
		ans += (k - a) // aa[0]
	print(ans)


import sys
import math
import bisect
from sys import stdin, stdout
from math import gcd, floor, sqrt, log
from collections import defaultdict as dd
from bisect import bisect_left as bl, bisect_right as br
from collections import Counter
inp = lambda : int(input())
strng = lambda : input().strip()
jn = lambda x, l: x.join(map(str, l))
strl = lambda : list(input().strip())
mul = lambda : map(int, input().strip().split())
mulf = lambda : map(float, input().strip().split())
seq = lambda : list(map(int, input().strip().split()))
ceil = lambda x: int(x) if x == int(x) else int(x) + 1
ceildiv = lambda x, d: x // d if x % d == 0 else x // d + 1
flush = lambda : stdout.flush()
stdstr = lambda : stdin.readline()
stdint = lambda : int(stdin.readline())
stdpr = lambda x: stdout.write(str(x))
stdarr = lambda : map(int, stdstr().split())
mod = 1000000007
for i in range(stdint()):
	(n, k) = stdarr()
	arr = list(stdarr())
	arr.sort()
	res = 0
	m = arr[0]
	for i in range(1, n):
		diff = k - arr[i]
		res += max(diff // m, 0)
	print(res)


from collections import *
from itertools import *
from bisect import *

def inp():
	return int(input())

def arrinp():
	return [int(x) for x in input().split()]

def main():
	t = inp()
	for _ in range(t):
		(n, k) = arrinp()
		A = arrinp()
		A.sort()
		inc = A[0]
		ans = 0
		for i in A[1:]:
			ans += (k - i) // inc
		print(ans)
main()


def solve():
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	ans = 0
	for i in a[1:]:
		ans += (k - i) // a[0]
	print(ans)
	return

def main():
	t = 1
	t = int(input())
	for _ in range(t):
		solve()
main()


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	L = sorted(list(map(int, input().split())))
	c = L[0]
	a = 0
	for i in L[1:]:
		if i <= k:
			a = a + (k - i) // c
	print(a)


import sys
try:
	(sys.stdin, sys.stdout) = (open('in.txt', 'r'), open('out.txt', 'w'))
except:
	pass
ii1 = lambda : int(sys.stdin.readline().strip())
is1 = lambda : sys.stdin.readline().strip()
iia = lambda : list(map(int, sys.stdin.readline().strip().split()))
isa = lambda : sys.stdin.readline().strip().split()
mod = int(1000000000.0 + 7)
from collections import *
from math import *
for _ in range(ii1()):
	(n, k) = iia()
	arr = iia()
	arr.sort()
	a = arr[0]
	ans = 0
	for i in range(1, n):
		if arr[i] < k:
			diff = k - arr[i]
			ans += diff // a
	print(ans)


import os
import sys
from io import BytesIO, IOBase

def main():
	pass
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
main()

def test():
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	t = min(a)
	ti = a.index(min(a))
	r = 0
	for i in range(n):
		if i != ti and a[i] + t <= k:
			r += (k - a[i]) // t
	return r
t = int(input())
for _ in range(t):
	print(test())


import sys
input = iter(sys.stdin.read().splitlines()).__next__
T = int(input())
for _ in range(T):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	i = a.index(min(a))
	print(sum(((k - a[j]) // a[i] for j in range(n))) - (k - a[i]) // a[i])


for t in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	y = a[0]
	ans = sum(((k - x) // y for x in a[1:]))
	print(ans)


import itertools
import math
import sys
from collections import defaultdict

def stdinWrapper():
	data = '3\n2 2\n1 1\n3 5\n1 2 3\n3 7\n3 2 2\n\n\n\n'
	for line in data.split('\n'):
		yield line
if '--debug' not in sys.argv:

	def stdinWrapper():
		while True:
			yield sys.stdin.readline()
inputs = stdinWrapper()

def inputWrapper():
	return next(inputs)

def getType(_type):
	return _type(inputWrapper())

def getArray(_type):
	return [_type(x) for x in inputWrapper().split()]

def solve(a, k):
	min_i = 0
	for i in range(1, len(a)):
		if a[i] < a[min_i]:
			min_i = i
	res = 0
	for i in range(0, len(a)):
		if i == min_i:
			continue
		res += (k - a[i]) // a[min_i]
	return res
t = getType(int)
for _ in range(t):
	(n, k) = getArray(int)
	a = getArray(int)
	res = solve(a, k)
	print(res)


t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	a = min(l)
	l.remove(a)
	count = 0
	for j in range(n - 1):
		if l[j] < k:
			count += (k - l[j]) // a
	print(count)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	li = [int(i) for i in input().split()]
	min_value = min(li)
	li.remove(min_value)
	r = 0
	for num in li:
		r += (k - num) // min_value
	print(r)


for _ in range(int(input())):
	(n, k) = input().split()
	n = int(n)
	k = int(k)
	a = sorted([int(x) for x in input().split()])
	res = 0
	inc = a[0]
	for i in range(1, n):
		res += (k - a[i]) // inc
	print(res)


T = input()
T = int(T)
for t in range(T):
	(n, k) = input().split()
	n = int(n)
	k = int(k)
	arr = [int(v) for v in input().split()]
	min_amount = k
	min_i = 0
	for (i, a) in enumerate(arr):
		if a < min_amount:
			min_amount = a
			min_i = i
	res = 0
	for a in arr[:min_i] + arr[min_i + 1:]:
		res += (k - a) // min_amount
	print(res)


import sys
import math

def II():
	return int(sys.stdin.readline())

def LI():
	return list(map(int, sys.stdin.readline().split()))

def MI():
	return list(map(int, sys.stdin.readline().split()))

def SI():
	return sys.stdin.readline().strip()
t = II()
for q in range(t):
	(n, k) = MI()
	a = LI()
	a.sort()
	count = 0
	for i in range(1, n):
		b = max(k - a[i], 0)
		count += b // a[0]
	print(count)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	res = min(a)
	ind = a.index(res)
	ans = 0
	for i in range(n):
		if i != ind:
			ans += (k - a[i]) // res
	print(ans)


t = int(input())
test_cases = []
for i in range(t):
	case = []
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	case.append(n)
	case.append(k)
	case.append(arr)
	test_cases.append(case)
for case in test_cases:
	n = case[0]
	k = case[1]
	arr = case[2]
	arr.sort()
	accum = 0
	for a in arr[1:]:
		accum += (k - a) // arr[0]
	print(accum)


def maxChange(a, k):
	a.sort()
	res = 0
	for i in range(1, len(a)):
		res += (k - a[i]) // a[0]
	return res
t = int(input())
for i in range(t):
	(n, k) = [int(x) for x in input().split()]
	a = [int(x) for x in input().split()]
	print(maxChange(a, k))


from math import floor

def smallest_index(t):
	small = t[0]
	index = 0
	for (i, elem) in enumerate(t):
		if elem < small:
			small = elem
			index = i
	return (index, small)
t = int(input())
for _ in range(t):
	(n, k) = [int(x) for x in input().split()]
	a = [int(x) for x in input().split()]
	answ = 0
	(index, small) = smallest_index(a)
	for i in range(n):
		if i != index:
			answ += floor((k - a[i]) / small)
	print(answ)


get_int = lambda : int(input())
get_list = lambda : list(map(int, input().rstrip().split()))
TEST_CASES = True

def main():
	(n, k) = get_list()
	a = get_list()
	a.sort()
	s = 0
	for i in range(1, n):
		diff = k - a[i]
		s += diff // a[0]
	print(s)
if not TEST_CASES:
	main()
else:
	[main() for _ in range(int(input()))]


t = int(input())
for i in range(t):
	(n, k) = list(map(int, input().split()))
	x = list(map(int, input().split()))
	count = 0
	z = min(x)
	x.remove(z)
	for i in range(len(x)):
		count += (k - x[i]) // z
	print(count)


for i in range(int(input())):
	l = 0
	(n, k) = map(int, input().split())
	f = list(map(int, input().split()))
	h = min(f)
	g = f.index(h)
	for j in range(len(f)):
		if f[j] + h <= k and j != g:
			l = l + (k - f[j]) // h
	print(l)


t = int(input())
for _ in range(t):
	(n, k) = [int(p) for p in input().split()]
	arr = sorted([int(p) for p in input().split()])
	count = 0
	for i in range(1, n):
		count += (k - arr[i]) // arr[0]
	print(count)


for i in range(int(input())):
	(a, b) = list(map(int, input().split()))
	l = list(map(int, input().split()))
	s = 0
	l.sort()
	for i in range(1, a):
		if b > l[i]:
			s = s + (b - l[i]) // l[0]
	print(s)


for _ in range(int(input())):
	(n, k) = [int(w) for w in input().split()]
	x = [int(w) for w in input().split()]
	y = min(x)
	del x[x.index(y)]
	a = 0
	for i in x:
		a += (k - i) // y
	print(a)


from sys import stdin
for _ in range(int(stdin.readline())):
	(n, k) = map(int, stdin.readline().strip().split())
	l = list(map(int, stdin.readline().strip().split()))
	s = 0
	l.sort()
	a = l[0]
	for i in range(1, n):
		if l[i] >= k:
			break
		elif l[i] < k:
			d = (k - l[i]) // a
			s += d
	print(s)


def solve(n, k):
	s = list(map(int, input().split()))
	s.sort()
	ans = 0
	p = s[0]
	for i in range(1, n):
		ans += (k - s[i]) // p
	print(ans)
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	solve(n, k)


import sys
input = sys.stdin.readline

def inp():
	return int(input())

def inlt():
	return list(map(int, input().split()))

def invr():
	return map(int, input().split())
T = inp()
for t in range(T):
	(n, k) = invr()
	a = inlt()
	a.sort()
	cast_number = 0
	min_candies = a[0]
	cast_number = sum(((k - y) // min_candies for y in a[1:]))
	sys.stdout.write(str(cast_number) + '\n')


t = int(input())
while t:
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a = sorted(a)
	count = 0
	for i in range(1, n):
		if k >= a[i]:
			count = count + int((k - a[i]) / a[0])
	print(count)
	t -= 1


for t in range(int(input())):
	(n, k) = map(int, input().split())
	ls = list(map(int, input().split()))
	m = min(ls)
	x = ls.index(m)
	i = 0
	ans = 0
	for i in range(n):
		if i != x:
			ans += int((k - ls[i]) // m)
	print(ans)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	Min = min(a)
	a.remove(Min)
	b = [k - i for i in a]
	ans = 0
	for i in b:
		if i == 0:
			continue
		ans += i // Min
	print(ans)


for test in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	l.sort()
	z = 0
	flag = 0
	for i in range(1, n):
		if l[i] > k:
			flag = 1
			break
		z = z + (k - l[i]) // l[0]
	if flag == 0:
		print(z)
	else:
		print(0)


def max_magic(arr, k):
	min_el = k
	stop_i = 0
	for (i, el) in enumerate(arr):
		if el <= min_el:
			min_el = el
			stop_i = i
	total_count = 0
	count = 1
	while count != 0:
		count = 0
		for i in range(len(arr)):
			if i == stop_i:
				continue
			if arr[i] + min_el <= k:
				count += 1
				arr[i] += min_el
		total_count += count
	return total_count
n_cases = int(input())
for i in range(n_cases):
	(n, k) = list(map(int, input().split()))
	arr = list(map(int, input().split()))
	total = max_magic(arr, k)
	print(total)


for y in ' ' * int(input()):
	(n, k) = map(int, input().split(' '))
	a = list(map(int, input().split(' ')))
	m = min(a)
	a.remove(m)
	print(sum(list(map(lambda i: (k - i) // m, a))))


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	m = min(l)
	l.remove(m)
	out = 0
	for i in range(n - 1):
		out += (k - l[i]) // m
	print(out)


from collections import defaultdict, Counter
from math import log, ceil, floor

def solve():
	(n, k) = list(map(int, input().split()))
	a = list(map(int, input().split()))
	ans = 0
	a.sort()
	for i in a[1:]:
		req = k - i
		ans += req // a[0]
	print(ans)
t = 1
t = int(input())
for _ in range(t):
	solve()


import math
teststring = '3\n2 2\n1 1\n3 5\n1 2 3\n3 7\n3 2 2\n'
online = __file__ != '/home/jhli/py/header.py'
(true, false) = (True, False)
if True:

	def spitout():
		for c in teststring.splitlines():
			yield c
	_ito = spitout()
	if not online:

		def input():
			return next(_ito)

	def build_enum(*a):
		built = dict()
		for (i, c) in enumerate(a):
			built[c] = i
		return lambda x: built[x]
T = int(input())
for ti in range(1, T + 1):
	[n, k] = map(int, input().split(' '))
	a = []
	a.extend([int(e) for e in input().split(' ')])
	sum = 0
	m = min(a)
	for i in range(n):
		sum += int(math.floor((k - a[i]) / m))
	sum -= int(math.floor((k - m) / m))
	print(sum)


import math
t = int(input())
while t:
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	count = 0
	l.sort()
	s = l[0]
	ans = res = 0
	for i in range(1, n):
		res = k - l[i]
		ans += res // s
	print(ans)
	t -= 1


t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	a = [int(l) for l in input().split()]
	b = 0
	a = sorted(a)
	for j in range(1, len(a)):
		while a[j] + a[0] <= k:
			b += 1
			a[j] += a[0]
	print(b)
	b = 0


import math
T = int(input())
for t in range(T):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	d = False
	ma = min(a)
	mai = a.index(ma)
	ans = 0
	for i in range(n):
		if i != mai:
			ans += (k - a[i]) // ma
			a[i] += ma * ((k - a[i]) // ma)
			if a[i] > k:
				print(0)
				d = True
	a.remove(ma)
	mma = min(a)
	ans += (k - ma) // mma
	if not d:
		print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	cnt = 0
	new = sorted(a)
	for i in range(1, n):
		s = (k - new[i]) // min(new)
		cnt += s
	print(cnt)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	m = a.pop(a.index(min(a)))
	s = 0
	for i in a:
		s += (k - i) // m
	print(s)


T = int(input())
while T:
	(N, K) = (int(i) for i in input().split())
	A = [int(i) for i in input().split()]
	A = sorted(A)
	i = 0
	ans = 0
	for j in range(1, N):
		temp = (K - A[j]) // A[i]
		ans += temp
	print(ans)
	T -= 1


(z, zz) = (input, lambda : list(map(int, z().split())))
zzz = lambda : [int(i) for i in stdin.readline().split()]
(szz, graph, mod, szzz) = (lambda : sorted(zz()), {}, 10 ** 9 + 7, lambda : sorted(zzz()))
from string import *
from re import *
from collections import *
from queue import *
from sys import *
from collections import *
from math import *
from heapq import *
from itertools import *
from bisect import *
from collections import Counter as cc
from math import factorial as f
from bisect import bisect as bs
from bisect import bisect_left as bsl
from itertools import accumulate as ac

def lcd(xnum1, xnum2):
	return xnum1 * xnum2 // gcd(xnum1, xnum2)

def prime(x):
	p = ceil(x ** 0.5) + 1
	for i in range(2, p):
		if x % i == 0 and x != 2 or x == 0:
			return 0
	return 1

def dfs(u, visit, graph):
	visit[u] = True
	for i in graph[u]:
		if not visit[i]:
			dfs(i, visit, graph)
num = 1
num = int(z())
for _ in range(num):
	(n, k) = zz()
	arr = szzz()
	t = arr[0]
	ans = 0
	for i in arr[1:]:
		if k >= i:
			ans += (k - i) // t
	print(ans)


T = int(input())
for _ in range(T):
	(n, k) = list(map(int, input().split()))
	a = list(map(int, input().split()))
	minimum = i = float('inf')
	for t in range(n):
		if minimum > a[t]:
			minimum = a[t]
			i = t
	count = 0
	for j in range(n):
		if j != i:
			while True:
				if a[j] > k:
					count -= 1
					break
				elif a[j] == k:
					break
				else:
					a[j] += a[i]
					count += 1
	print(count)


t = int(input())
for test in range(t):
	(n, k) = input().split(' ')
	n = int(n)
	k = int(k)
	l = [int(i) for i in input().split(' ')]
	count = 0
	m = min(l)
	l1 = l.remove(m)
	for i in l:
		c = max(k - i, 0) // m
		count += c
	print(count)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	m = min(a)
	ans = 0
	flag = False
	for i in range(n):
		if a[i] != m or flag:
			ans += (k - a[i]) // m
		else:
			flag = True
	print(ans)


import sys
from math import sqrt, gcd, ceil, log, floor
from bisect import bisect, bisect_left
from collections import defaultdict, Counter, deque
from heapq import heapify, heappush, heappop
input = sys.stdin.readline
read = lambda : list(map(int, input().strip().split()))
MOD = 998244353

def f(n):
	if n < 10:
		return n
	return f(n % 10 + f(n // 10))

def main():
	ans = []
	for _ in range(int(input())):
		(n, k) = read()
		arr = read()
		arr.sort()
		elem = arr[0]
		c = 0
		for i in range(1, n):
			c += (k - arr[i]) // elem
		ans.append(str(c))
	print('\n'.join(ans))
main()


t = int(input())
for fdsfsd in range(t):
	first = str(input()).split()
	n = int(first[0])
	k = int(first[1])
	a = [int(b) for b in str(input()).split()]
	a.sort()
	m = 0
	for i in range(1, n):
		if a[i] >= k:
			continue
		m += int((k - a[i]) / a[0])
	print(m)


import sys, math, cmath, time
start_time = time.time()

def solve():
	(n, k) = invr()
	a = inlt()
	a.sort()
	q = min(a)
	c = 0
	for i in range(1, len(a)):
		c = c + (k - a[i]) // q
	print(c)

def main():
	global tt
	if not ONLINE_JUDGE:
		sys.stdin = open('input.txt', 'r')
		sys.stdout = open('output.txt', 'w')
	t = 1
	t = inp()
	for tt in range(1, t + 1):
		solve()
	if not ONLINE_JUDGE:
		print('Time Elapsed :', time.time() - start_time, 'seconds')
		sys.stdout.close()

def inp():
	return int(input())

def inlt():
	return list(map(int, input().split()))

def insr():
	return input().strip()

def invr():
	return map(int, input().split())

def counter(a):
	q = [0] * max(a)
	for i in range(len(a)):
		q[a[i] - 1] = q[a[i] - 1] + 1
	return q

def counter_elements(a):
	q = dict()
	for i in range(len(a)):
		if a[i] not in q:
			q[a[i]] = 0
		q[a[i]] = q[a[i]] + 1
	return q

def string_counter(a):
	q = [0] * 26
	for i in range(len(a)):
		q[ord(a[i]) - 97] = q[ord(a[i]) - 97] + 1
	return q

def factorial(n, m=1000000007):
	q = 1
	for i in range(n):
		q = q * (i + 1) % m
	return q

def factors(n):
	q = []
	for i in range(1, int(n ** 0.5) + 1):
		if n % i == 0:
			q.append(i)
			q.append(n // i)
	return list(sorted(list(set(q))))

def prime_factors(n):
	q = []
	while n % 2 == 0:
		q.append(2)
		n = n // 2
	for i in range(3, int(n ** 0.5) + 1, 2):
		while n % i == 0:
			q.append(i)
			n = n // i
	if n > 2:
		q.append(n)
	return list(sorted(q))

def transpose(a):
	(n, m) = (len(a), len(a[0]))
	b = [[0] * n for i in range(m)]
	for i in range(m):
		for j in range(n):
			b[i][j] = a[j][i]
	return b

def ceil(a, b):
	return -(-a // b)
ONLINE_JUDGE = __debug__
if ONLINE_JUDGE:
	input = sys.stdin.readline
main()


n = int(input())
for i in range(n):
	(a, k) = map(int, input().split())
	b = list(map(int, input().split()))
	b.sort()
	total = 0
	for i in range(1, a):
		total += (k - b[i]) // b[0]
	print(total)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	l1 = [int(x) for x in input().split()]
	smol = min(l1)
	l1.remove(min(l1))
	ans = 0
	for x in l1:
		ans += (k - x) // smol
	print(ans)


import sys
t = int(input())
while t > 0:
	t -= 1
	input = sys.stdin.readline()
	(n, k) = map(int, input.split())
	input = sys.stdin.readline()
	arr = list(map(int, input.split()))
	pos = arr.index(min(arr))
	min_value = arr[pos]
	ans = 0
	for i in range(n):
		if i != pos:
			ans += (k - arr[i]) // min_value
	print(ans)


t = int(input())
while t:
	t = t - 1
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	mn = min(a)
	ind = a.index(mn)
	out = 0
	for i in range(n):
		if i == ind:
			continue
		z = k - a[i]
		out += z // mn
	print(out)


from sys import stdin

def solve(n, k, arr):
	arr.sort()
	total = 0
	for i in range(1, n):
		if arr[i] > k:
			continue
		else:
			total += (k - arr[i]) // arr[0]
	return total
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	arr = list(map(int, stdin.readline().split()))
	print(solve(n, k, arr))


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	a = [int(x) for x in input().split()]
	m = min(a)
	a.remove(m)
	c = 0
	for i in a:
		c += (k - i) // m
	print(c)


import sys
input = lambda : sys.stdin.readline().rstrip('\r\n')
t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	a = [int(x) for x in input().split()]
	a.sort()
	ans = 0
	for i in a[1:]:
		ans += (k - i) // a[0]
	print(ans)


import sys, os.path
sys.setrecursionlimit(10 ** 5)

def mod():
	return 1000000007

def ii():
	return int(sys.stdin.readline())

def si():
	return sys.stdin.readline().strip()

def li():
	return list(sys.stdin.readline().strip())

def mii():
	return map(int, sys.stdin.readline().split())

def lii():
	return list(map(int, sys.stdin.readline().strip().split()))

def solve():
	(n, k) = mii()
	a = sorted(lii())
	b = 0
	for i in range(1, n):
		if a[i] < k:
			b += (k - a[i]) // a[0]
		else:
			break
	print(b)
for _ in range(ii()):
	solve()


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	x = list(map(int, input().split()))
	x = sorted(x)
	count = 0
	for i in range(1, n):
		while x[i] < k:
			x[i] += x[0]
			count += 1
		if x[i] > k:
			count -= 1
	print(count)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	lst = sorted([int(i) for i in input().split()])
	count = 0
	for i in range(1, n):
		count += (k - lst[i]) // lst[0]
	print(count)


import sys, collections, math, itertools

def get_ints():
	return map(int, sys.stdin.readline().strip().split())

def get_array():
	return list(map(int, sys.stdin.readline().strip().split()))

def input():
	return sys.stdin.readline().strip()
mod = 1000000007
for _ in range(int(input())):
	(n, k) = get_ints()
	arr = get_array()
	arr.sort()
	cnt = 0
	for i in range(1, n):
		while arr[i] + arr[0] <= k:
			arr[i] += arr[0]
			cnt += 1
	print(cnt)


import collections
for t in range(int(input())):
	(n, k) = map(int, input().split())
	num = sorted(map(int, input().split()))
	val = num.pop(0)
	out = 0
	for i in num:
		out += max(0, k - i) // val
	print(out)


for i in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	mini = a[0]
	ans = 0
	for i in range(1, len(a)):
		ans += (k - a[i]) // mini
	print(ans)


for _ in range(int(input())):
	(n, k) = [int(x) for x in input().split()]
	a = [int(x) for x in input().split()]
	ss = 0
	a.sort()
	for i in range(1, n):
		ss += (k - a[i]) // a[0]
	print(ss)


import sys
t = int(sys.stdin.readline().strip())
for _ in range(t):
	(n, k) = list(map(int, sys.stdin.readline().strip().split()))
	a = list(map(int, sys.stdin.readline().strip().split()))
	it_m = 0
	for i in range(n):
		if a[it_m] >= a[i]:
			it_m = i
	count = 0
	for i in range(n):
		if i != it_m:
			count += (k - a[i]) // a[it_m]
	print(count)


for _ in range(int(input())):
	(n, k) = [int(i) for i in input().split()]
	arr = [int(i) for i in input().split()]
	arr.sort()
	count = 0
	for i in range(1, n):
		s = arr[i]
		if k - s > 0:
			avail = k - s
			rem = avail // arr[0]
			count += rem
	print(count)


n = int(input())
for i in range(n):
	(num, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	first = arr.pop(arr.index(min(arr)))
	print(sum(((k - i) // first for i in arr)))


for i in range(int(input())):
	(n, k) = map(int, input().split())
	a = [int(i) for i in input().split()]
	a = sorted(a)
	c = 0
	x = a[0]
	i = 1
	while i != n:
		if a[i] + x <= k:
			a[i] = x + a[i]
			c += 1
		else:
			i += 1
	print(c)


from __future__ import division, print_function
import os
import sys
from io import BytesIO, IOBase
if sys.version_info[0] < 3:
	from __builtin__ import xrange as range
	from future_builtins import ascii, filter, hex, map, oct, zip

def main():
	t = int(input())
	for _ in range(t):
		(n, k) = map(int, input().split())
		a = sorted([int(ai) for ai in input().split()])
		sol = 0
		for i in range(1, n):
			sol += (k - a[i]) // a[0]
		print(sol)
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')

def print(*args, **kwargs):
	(sep, file) = (kwargs.pop('sep', ' '), kwargs.pop('file', sys.stdout))
	at_start = True
	for x in args:
		if not at_start:
			file.write(sep)
		file.write(str(x))
		at_start = False
	file.write(kwargs.pop('end', '\n'))
	if kwargs.pop('flush', False):
		file.flush()
if sys.version_info[0] < 3:
	(sys.stdin, sys.stdout) = (FastIO(sys.stdin), FastIO(sys.stdout))
else:
	(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
main()


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	x = min(l)
	l.remove(x)
	c = 0
	for i in l:
		c += int((k - i) / x)
	print(c)


import math
pi = math.acos(-1)
T = int(input())
for _ in range(T):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	ans = 0
	for i in range(1, n):
		ans = ans + (k - a[i]) // a[0]
	print(ans)


for i in range(int(input())):
	(n, k) = [int(i) for i in input().split()]
	arr = [int(i) for i in input().split()]
	res = 0
	flag = 0
	temp = min(arr)
	app = 0
	for i in range(n):
		if arr[i] == temp and (not app):
			app = 1
			continue
		elif arr[i] == temp and app:
			res += (k - arr[i]) // temp
		else:
			res += (k - arr[i]) // temp
	print(res)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	arr.sort()
	pick = arr[0]
	ans = 0
	for i in range(1, n):
		num = k - arr[i]
		q = num // pick
		if pick * q + arr[i] <= k:
			ans += q
		else:
			ans += q - 1
	print(ans)


t = int(input())
for items in range(t):
	(n, k) = map(int, input().split())
	x = sorted(list(map(int, input().split())))[:n]
	count = 0
	for i in range(1, n):
		if x[i] >= k:
			break
		else:
			count += (k - x[i]) // x[0]
	print(count)


import os
import sys
from io import BytesIO, IOBase
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
from math import gcd, ceil

def pre(s):
	n = len(s)
	pi = [0] * n
	for i in range(1, n):
		j = pi[i - 1]
		while j and s[i] != s[j]:
			j = pi[j - 1]
		if s[i] == s[j]:
			j += 1
		pi[i] = j
	return pi

def prod(a):
	ans = 1
	for each in a:
		ans = ans * each
	return ans

def lcm(a, b):
	return a * b // gcd(a, b)

def binary(x, length=16):
	y = bin(x)[2:]
	return y if len(y) >= length else '0' * (length - len(y)) + y
for _ in range(int(input()) if True else 1):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a = sorted(a)
	if a[-1] > k:
		print(0)
		continue
	ans = 0
	for i in range(1, n):
		ans += (k - a[i]) // a[0]
	print(ans)


import sys
for test in range(int(input())):
	(n, k) = map(int, sys.stdin.readline().split())
	arr = sorted([int(x) for x in sys.stdin.readline().split()])
	count = 0
	lim = arr[0]
	for x in range(1, n):
		if (k - arr[x]) // lim <= 0:
			pass
		else:
			count += (k - arr[x]) // lim
	print(count)


import math
t = int(input())
while t:
	t -= 1
	(n, k) = map(int, input().split())
	a = [int(i) for i in input().split()]
	a.sort()
	ans = 0
	mi = a[0]
	for i in range(1, n):
		ans += math.floor((k - a[i]) / mi)
	print(int(ans))


t = int(input())
for i in range(t):
	res = 0
	(n, k) = map(int, input().split())
	candy = list(map(int, input().split()))
	lower_num = min(candy)
	TrueOrFalse = False
	for item in candy:
		if lower_num != item or TrueOrFalse:
			res += (k - item) // lower_num
		else:
			TrueOrFalse = True
	print(res)


for t in range(int(input())):
	(num, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	arr.sort()
	count = 0
	for i in range(1, len(arr)):
		if k - arr[i] > 0:
			count += (k - arr[i]) // arr[0]
	print(count)


import os
import sys
import io
GANS = []
t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	li = [int(i) for i in input().split()]
	m = min(li)
	li.remove(m)
	ans = 0
	for i in li:
		ans += int((k - i) / m)
	print(ans)


t = int(input())
for i in range(t):
	(n, m) = [int(x) for x in input().split()]
	a = [int(x) for x in input().split()]
	idx = 0
	mini = a[0]
	for i in range(len(a)):
		if a[i] < mini:
			idx = i
			mini = a[i]
	ans = 0
	for i in range(len(a)):
		if i == idx:
			continue
		ans += (m - a[i]) // mini
	print(ans)


t = int(input())
for _ in range(t):
	(n, k) = [int(x) for x in input().split()]
	a = [int(x) for x in input().split()]
	a.sort()
	if a[-1] > k:
		ans = 0
	else:
		ans = 0
		for i in range(1, n):
			ans += (k - a[i]) // a[0]
	print(ans)


def answer(arr, n, k):
	count = 0
	arr.sort()
	x = arr[0]
	for i in range(1, n):
		y = (k - arr[i]) // x
		count += y
	return count
t = int(input())
while t > 0:
	(n, k) = map(int, input().strip().split())
	pile = list(map(int, input().strip().split()))
	print(answer(pile, n, k))
	t -= 1


N = int(input())
from bisect import bisect_left
for _ in range(N):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	res = 0
	arr.sort()
	mi = arr[0]
	for i in range(n - 1, 0, -1):
		dif = k - arr[i]
		if dif <= 0:
			continue
		res += dif // mi
	print(res)


test = int(input())
for q in range(test):
	(n, k) = map(int, input().split())
	x = list(map(int, input().split()))
	x.sort()
	c = 0
	for i in range(1, n):
		c += (k - x[i]) // x[0]
	print(c)


t = int(input())
for i in range(0, t):
	(n, k) = [int(x) for x in input().split()]
	v = [int(x) for x in input().split()]
	v.sort()
	ans = 0
	for j in range(1, n):
		x = k - v[j]
		ans += x // v[0]
	print(ans)


for _ in range(int(input())):
	(x, y) = map(int, input().split())
	(*li,) = map(int, input().split())
	cnt = 0
	li.sort()
	a = li[0]
	for i in li[1:]:
		if y - i > 0:
			cnt += (y - i) // a
	print(cnt)


t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	y = a[0]
	c = 0
	for j in range(1, len(a)):
		r = k - a[j]
		if r > 0:
			c = c + r // y
	print(c)


import sys
from copy import *
from bisect import *
from heapq import *
from itertools import permutations as prm, product

def eprint(*args):
	print(*args, file=sys.stderr)
zz = 1
if zz:
	input = sys.stdin.readline
else:
	sys.stdin = open('input.txt', 'r')
	sys.stdout = open('all.txt', 'w')
di = [[-1, 0], [1, 0], [0, 1], [0, -1]]

def string(s):
	return ''.join(s)

def fori(n):
	return [fi() for i in range(n)]

def inc(d, c, x=1):
	d[c] = d[c] + x if c in d else x

def bo(i):
	return ord(i) - ord('A')

def li():
	return [int(xx) for xx in input().split()]

def fli():
	return [float(x) for x in input().split()]

def comp(a, b):
	if a > b:
		return 2
	return 2 if a == b else 0

def gi():
	return [xx for xx in input().split()]

def fi():
	return int(input())

def pro(a):
	return reduce(lambda a, b: a * b, a)

def swap(a, i, j):
	(a[i], a[j]) = (a[j], a[i])

def si():
	return list(input().rstrip())

def mi():
	return map(int, input().split())

def gh():
	sys.stdout.flush()

def isvalid(i, j):
	return 0 <= i < n and 0 <= j < m and (a[i][j] != '.')

def bo(i):
	return ord(i) - ord('a')

def graph(n, m):
	for i in range(m):
		(x, y) = mi()
		a[x].append(y)
		a[y].append(x)
t = fi()
while t > 0:
	t -= 1
	(n, k) = mi()
	a = li()
	a.sort()
	ans = 0
	m = a[0]
	for i in range(1, n):
		ans += max(0, -a[i] + k) // a[0]
	print(ans)


import sys
input = sys.stdin.buffer.readline
t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	ind = a.index(min(a))
	ans = 0
	for i in range(n):
		if i != ind:
			ans += (k - a[i]) // a[ind]
	print(ans)


for t in range(int(input())):
	(n, k) = map(int, input().split())
	l1 = list(map(int, input().split()))
	l2 = []
	for i in range(n):
		l2.append((k - l1[i]) // min(l1))
	print(sum(l2) - (k - min(l1)) // min(l1))


import sys

def get_ints():
	return list(map(int, sys.stdin.readline().strip().split()))

def solve(nums, k):
	ans = 0
	min_element = nums.index(min(nums))
	for i in range(len(nums)):
		if i != min_element:
			while nums[i] + nums[min_element] <= k:
				nums[i] += nums[min_element]
				ans += 1
	return ans
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	nums = get_ints()
	print(solve(nums, k))


for _ in range(0, int(input())):
	(n, k) = map(int, input().split())
	(m, *v) = sorted(list(map(int, input().split())))
	print(sum([(k - x) // m for x in v]))


t = int(input())
for _ in range(t):
	n = list(map(int, input().split()))
	a = list(map(int, input().split()))
	m = min(a)
	j = 0
	out = 0
	for i in range(n[0]):
		if a[i] == m and j == 0:
			j = j + 1
		else:
			out = out + (n[1] - a[i]) // m
	print(out)


def question1():
	(N, K) = map(int, input().split())
	arr = list(map(int, input().split()))
	ans = 0
	min1 = min(arr)
	arr.remove(min1)
	for i in range(N - 1):
		diff = K - arr[i]
		if diff > 0:
			ans += diff // min1
	return ans
remained_test_cases = int(input())
while remained_test_cases > 0:
	print(question1())
	remained_test_cases -= 1


def read_ints():
	return map(int, input().split())
(t,) = read_ints()
for i_t in range(t):
	(n, k) = read_ints()
	a_seq = list(read_ints())
	min_a = min(a_seq)
	a_seq.remove(min_a)
	result = 0
	for a in a_seq:
		if a < k:
			result += (k - a) // min_a
	print(result)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	c = 0
	r = min(l)
	l.remove(r)
	for i in l:
		while i < k:
			i = i + r
			c += 1
			if i > k:
				c -= 1
	print(c)


from math import log2
t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	arr.sort()
	res = 0
	for i in range(1, n):
		if arr[i] >= k:
			break
		res += (k - arr[i]) // arr[0]
	print(res)


t = int(input())
for i in range(t):
	count = 0
	(n, k) = [int(x) for x in input().split()]
	a = [int(x) for x in input().split()]
	mi = min(a)
	ch = a.index(mi)
	for j in range(n):
		if j != ch:
			count += (k - a[j]) // mi
	print(count)


for t in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	ans = 0
	for i in range(1, n):
		if a[i] < k:
			ans += (k - a[i]) // a[0]
		else:
			break
	print(ans)


for _ in range(int(input())):
	(n, k) = [int(token) for token in input().split()]
	a = [int(token) for token in input().split()]
	a.sort()
	print(sum(((k - a_i) // a[0] if k - a_i >= 0 else 0 for a_i in a[1:])))


t = int(input())
for _ in range(t):
	(n, k) = input().split()
	(n, k) = (int(n), int(k))
	l = list(map(int, input().split()))
	l.sort()
	s = l[0]
	c = 0
	for i in l[1:]:
		c += (k - i) // s
	print(c)


for _ in range(int(input())):
	(n, k) = tuple(map(int, input().split()))
	arr = list(map(int, input().split()))
	m = min(arr)
	was = False
	ans = 0
	for j in arr:
		if j == m and (not was):
			was = True
		else:
			ans += (k - j) // m
	print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	mini = min(a)
	ind = a.index(mini)
	count = 0
	for i in range(n):
		if i != ind:
			left = k - a[i]
			count += left // mini
	print(count)


def fun(arr, n, k):
	arr = sorted(arr)
	res = 0
	st = 0
	en = n - 1
	while st < en:
		if arr[st] + arr[en] <= k:
			dif = k - arr[en]
			mul = dif // arr[st]
			res += mul
			arr[en] += mul * arr[st]
		en -= 1
	return res
try:
	t = int(input())
	for i in range(t):
		(n, k) = list(map(int, input().split()))
		arr = list(map(int, input().split()))
		print(fun(arr, n, k))
except:
	pass


import math
import re
import itertools
import copy
import time
import sys
import functools

def input_linear(lamb=lambda x: int(x), seperator=' '):
	return map(lamb, input().split(seperator))

def input_array(lamb=lambda x: int(x), seperator=' '):
	return list(map(lamb, input().split(seperator)))

def input_matrix(rows, lamb=lambda x: int(x), seperator=' '):
	tmp_matrix = []
	for i in range(rows):
		tmp_matrix.append(input_array(lamb, seperator))
	return tmp_matrix

def input_graph_al_pair(vertices, lines, lamb=lambda x: int(x), seperator=' ', directional=False, remove_dup=False):
	temp_matrix = [x[:] for x in [[]] * vertices]
	if not directional:
		if not remove_dup:
			for i in range(lines):
				(ina, inb) = input_linear(lamb, seperator)
				temp_matrix[ina].append(inb)
				temp_matrix[inb].append(ina)
		else:
			for i in range(lines):
				(ina, inb) = input_linear(lamb, seperator)
				if inb not in temp_matrix[ina]:
					temp_matrix[ina].append(inb)
				if ina not in temp_matrix[inb]:
					temp_matrix[inb].append(ina)
		return temp_matrix
	else:
		if not remove_dup:
			for i in range(lines):
				(ina, inb) = input_linear(lamb, seperator)
				temp_matrix[ina].append(inb)
		else:
			for i in range(lines):
				(ina, inb) = input_linear(lamb, seperator)
				if inb not in temp_matrix[ina]:
					temp_matrix[ina].append(inb)
		return temp_matrix

def prettyp(a, typ='trash'):
	h = math.ceil(math.log(len(a), 2))
	for i in range(h):
		print(''.join(['  '] * (h - i)) + '  '.join(map(str, a[(1 << i) - 1:(1 << i + 1) - 1])))

def build_segment_t(a, lamb=lambda x, y: x + y):
	arr = [0] * len(a) + a.copy()
	for i in range(len(a) - 1, 0, -1):
		arr[i] = lamb(arr[i << 1], arr[i << 1 | 1])
	return arr

def mod_seg(a, pos, val):
	pos += len(a)
	a[pos] = val
	while pos > 1:
		a[pos >> 1] = a[pos] + a[pos ^ 1]
		pos >>= 1
for _ in range(int(input())):
	(n, k) = input_linear()
	a = input_array()
	cnt = 0
	mi = min(a)
	a.remove(mi)
	for i in range(n - 1):
		cnt += math.floor((k - a[i]) / mi)
	print(cnt)


t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	p = min(a)
	c = 0
	j = 0
	while j < n:
		if a[j] == p:
			del a[j]
			break
		j = j + 1
	for v in a:
		if v < k:
			c = c + (k - v) // p
	print(c)


import math
t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	st = input()
	a = list(map(int, st.split()))
	x = min(a)
	ind = a.index(x)
	found = 0
	count = 0
	j = 0
	while found == 0:
		if j == ind:
			j = j + 1
		if j >= n:
			break
		else:
			count = count + math.floor((k - a[j]) / x)
			j = j + 1
	print(count)


def iinput():
	return [int(i) for i in input().split()]
t = int(input())
for _ in range(t):
	(n, k) = iinput()
	mas = iinput()
	ans = 0
	mas = sorted(mas)
	mini = mas[0]
	for i in mas[1:]:
		ans += (k - i) // mini
	print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	l = [int(x) for x in input().split()]
	c = 0
	while max(l) <= k:
		m = min(l)
		i = l.index(m)
		flag = 0
		for j in range(n):
			if j != i:
				if l[j] + m <= k:
					flag = 1
					c += 1
					l[j] += m
		if flag == 0:
			break
	print(c)


t = int(input())
for i in range(t):
	count = 0
	(n, k) = map(int, input().split())
	p = list(map(int, input().split()))
	p.sort()
	for j in range(n - 1):
		count += int((k - p[j + 1]) / p[0])
	print(count)


def read_ints():
	return list(map(int, input().split()))

def read_int():
	return int(input())
T = read_int()
for _ in range(T):
	(n, k) = read_ints()
	a = read_ints()
	aMin = min(a)
	a.remove(aMin)
	b = [(k - ai) // aMin for ai in a]
	print(sum(b))


t = int(input())
for case in range(t):
	(n, k) = map(int, input().split())
	a = [int(x) for x in input().split()]
	m = min(a)
	out = 0
	for x in a:
		out += (k - x) // m
	out -= (k - m) // m
	print(out)


n = int(input())
for i in range(n):
	l = list(map(int, input().split()))
	l1 = list(map(int, input().split()))
	l1.sort()
	c = 0
	for j in range(1, l[0]):
		c += (l[-1] - l1[j]) // l1[0]
	print(c)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	a = l.index(min(l))
	az = min(l)
	count = 0
	l.pop(a)
	for q in range(len(l)):
		ass = (k - l[q]) // az
		l[q] += az * ass
		count += ass
	ass = (k - az) // min(l)
	count += ass
	print(count)


def solve():
	(n, k) = [int(v) for v in input().split()]
	arr = sorted([int(v) for v in input().split()])
	ans = 0
	for i in range(1, n):
		ans += max(0, k - arr[i]) // arr[0]
	print(ans)
t = int(input())
for _ in range(t):
	solve()


from bisect import bisect_left as bl
from bisect import bisect_right as br
from heapq import heappush, heappop, heapify
import math
from collections import *
from functools import reduce, cmp_to_key
import sys
input = sys.stdin.readline
from itertools import accumulate
from functools import lru_cache
M = mod = 998244353

def factors(n):
	return sorted(set(reduce(list.__add__, ([i, n // i] for i in range(1, int(n ** 0.5) + 1) if n % i == 0))))

def inv_mod(n):
	return pow(n, mod - 2, mod)

def li():
	return [int(i) for i in input().rstrip('\n').split()]

def st():
	return input().rstrip('\n')

def val():
	return int(input().rstrip('\n'))

def li2():
	return [i for i in input().rstrip('\n')]

def li3():
	return [int(i) for i in input().rstrip('\n')]
for _ in range(val()):
	(n, k) = li()
	l = li()
	l.sort()
	j = n - 1
	ans = 0
	while j > 0:
		ans += (k - l[j]) // l[0]
		j -= 1
	print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	mi = min(arr)
	midx = arr.index(mi)
	ans = 0
	if max(arr) > k:
		print(0)
		continue
	for a in range(n):
		if a == midx:
			continue
		ans += (k - arr[a]) // mi
	print(ans)


for cases in range(int(input())):
	(n, limit) = map(int, input().split())
	arr = list(map(int, input().split()))
	mini = min(arr)
	ans = 0 - (limit - mini) // mini
	for i in arr:
		ans += (limit - i) // mini
	print(ans)


import os
import sys
from io import BytesIO, IOBase
_str = str
BUFSIZE = 8192

def str(x=b''):
	return x if type(x) is bytes else _str(x).encode()

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')

def inp():
	return sys.stdin.readline()

def mpint():
	return map(int, sys.stdin.readline().split(' '))

def itg():
	return int(sys.stdin.readline())

def solve():
	(n, k) = mpint()
	arr = list(mpint())
	mn = arr.pop(min(range(n), key=arr.__getitem__))
	return sum(map(lambda a: (k - a) // mn, arr))
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
for _ in range(itg()):
	print(solve())


for _ in range(int(input())):
	(n, t) = map(int, input().split())
	arr = list(map(int, input().split()))
	ans = 0
	arr.sort()
	for j in range(1, n):
		ans += (t - arr[j]) // arr[0]
	print(ans)


def solve(n, l, k):
	ans = 0
	m = min(l)
	if m >= k:
		return 0
	l = sorted(l)
	for i in range(1, n):
		ans += (k - l[i]) // m
	return ans
t = int(input())
for we in range(t):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	print(solve(n, l, k))


T = int(input())
for t in range(T):
	(n, k) = list(map(int, input().split()))
	a = list(map(int, input().split()))
	a.sort()
	count = 0
	for i in range(1, n):
		count += (k - a[i]) // a[0]
	print(count)


for i in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	sumo = 0
	for j in range(1, n):
		sumo = sumo + (k - a[j]) // a[0]
	print(sumo)


def copy_paste(arr, k):
	min_val = min(arr)
	min_index = arr.index(min_val)
	moves = 0
	for (idx, val) in enumerate(arr):
		if idx != min_index:
			moves += (k - val) // min_val
	return moves
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	print(copy_paste(arr, k))


T = int(input())
for i in range(T):
	ch1 = input()
	ch2 = input()
	L1 = ch1.split()
	n = int(L1[0])
	k = int(L1[1])
	L2 = ch2.split()
	L = list()
	for j in range(n):
		L.append(int(L2[j]))
	L = sorted(L)
	s = 0
	for i in range(1, n):
		s += (k - L[i]) // L[0]
	print(s)


x1 = int(input())
for i in range(x1):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	c = 0
	d = min(l)
	l.sort()
	for i in range(1, n):
		c += (k - l[i]) // d
	print(c)


def solve(n, k, l):
	l.sort()
	smallest = l[0]
	count = 0
	for i in range(1, n):
		temp = k - l[i]
		count = count + temp // smallest
	return count
t = int(input())
while t:
	(n, k) = map(int, input().split(' '))
	l = list(map(int, input().split(' ')))
	print(solve(n, k, l))
	t = t - 1


import sys, io, os, time
from collections import defaultdict
from collections import Counter
from collections import deque
from itertools import combinations
from itertools import permutations
import bisect, math, heapq
alphabet = 'abcdefghijklmnopqrstuvwxyz'
input = sys.stdin.readline
for ii in range(int(input())):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	arr.sort()
	count = 0
	j = n - 1
	while j > 0:
		if arr[j] <= k:
			count += (k - arr[j]) // arr[0]
		j -= 1
	print(count)


for t in range(int(input())):
	(n, k) = list(map(int, input().split()))
	a = list(map(int, input().split()))
	m = min(a)
	ind = a.index(m)
	ans = 0
	for i in range(len(a)):
		if i != ind:
			ans += (k - a[i]) // m
	print(ans)


for _ in range(int(input())):
	(n, k) = list(map(int, input().split()))
	b = list(map(int, input().split()))
	b.sort()
	s = 0
	v = k
	for i in range(1, n):
		o = (v - b[i]) // b[0]
		s += o
		b[i] = b[i] + (v - b[i]) // b[0] * b[0]
	print(s)


import io
import os
from collections import Counter, defaultdict, deque

def solve(N, K, A):
	ans = 0
	mn1 = min(((x, i) for (i, x) in enumerate(A)))
	for (i, x) in enumerate(A):
		if i != mn1[1]:
			ans += max(0, K - x) // mn1[0]
	return ans
input = io.BytesIO(os.read(0, os.fstat(0).st_size)).readline
TC = int(input())
for tc in range(1, TC + 1):
	(N, K) = [int(x) for x in input().split()]
	A = [int(x) for x in input().split()]
	ans = solve(N, K, A)
	print(ans)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().strip().split()))[:n]
	ans = 0
	t = min(arr)
	arr.remove(t)
	for num in arr:
		if num >= k:
			continue
		else:
			ans += (k - num) // t
	print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split(' '))
	arr = [int(num) for num in input().split(' ')]
	arr.sort()
	ans = 0
	for item in arr[1:n]:
		ans = ans + (-item + k) // arr[0]
	print(ans)


from sys import stdin, stdout
from collections import deque
import bisect
R = lambda : stdin.readline().strip()
RL = lambda f=None: list(map(f, R().split(' '))) if f else list(R().split(' '))
output = lambda x: stdout.write(str(x) + '\n')
output_list = lambda x: output(' '.join(map(str, x)))
T = int(input())
for _ in range(T):
	(n, k) = RL(int)
	l = RL(int)
	mi = min(l)
	ans = 0
	for i in range(n):
		ans += (k - l[i]) // mi
	ans -= (k - mi) // mi
	print(ans)


cases = int(input())
for _ in range(cases):
	(n, k) = list(map(int, input().split()))
	arr = list(map(int, input().split()))
	l = min(arr)
	arr.remove(l)
	spells = 0
	for x in arr:
		spells += int((k - x) / l)
	print(spells)


import math
import sys

class Read:

	@staticmethod
	def string():
		return input()

	@staticmethod
	def int():
		return int(input())

	@staticmethod
	def list(sep=' '):
		return input().split(sep)

	@staticmethod
	def list_int(sep=' '):
		return list(map(int, input().split(sep)))

def solve():
	(n, k) = Read.list_int()
	a = Read.list_int()
	a.sort()
	m = a[0]
	res = 0
	for i in range(1, n):
		v = k - a[i]
		res = res + math.floor(v / m)
	print(res)
query_count = Read.int()
while query_count:
	query_count -= 1
	solve()


import sys
import math

class Solution:

	def __init__(self):
		pass

	def run(self):
		(n, k) = [int(i) for i in input().split()]
		piles = [int(i) for i in input().split()]
		piles = sorted(piles)
		if len(piles) == 0:
			return 0
		result = 0
		mn = piles[0]
		if mn >= k:
			return 0
		for p in range(len(piles) - 1, 0, -1):
			if piles[p] >= k:
				continue
			result += int((k - piles[p]) / mn)
		return result
t = int(input())
s = Solution()
for i in range(t):
	print(s.run())


for _ in range(int(input())):
	(n, k) = list(map(int, input().split()))
	ar = list(map(int, input().split()))
	m = min(ar)
	ans = sum(map(lambda x: (k - x) // m, ar))
	print(ans - (k - m) // m)


for i in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	cnt = 0
	for j in range(len(a)):
		if j != a.index(min(a)):
			cnt += (k - a[j]) // min(a)
	print(cnt)


import collections
from collections import defaultdict
import math
from collections import Counter
for _ in range(int(input())):
	(n, k) = [int(x) for x in input().split()]
	a = [int(x) for x in input().split()]
	a.sort()
	ans = 0
	x = a[0]
	for i in range(1, n):
		ans += (k - a[i]) // x
	print(ans)


import sys
input = sys.stdin.readline
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	m = a[0]
	c = 0
	for i in range(1, n):
		c += (k - a[i]) // m
	print(c)


def func(n, k, a):
	m = min(a)
	count = -int((k - m) / m)
	for i in a:
		count += int((k - i) / m)
	return count
m = input()
m = int(m)
for i in range(m):
	(n, k) = [int(x) for x in input().split()]
	a = [int(x) for x in input().split()]
	print(func(n, k, a))


from collections import defaultdict
import sys
import math

def get_array():
	return list(map(int, sys.stdin.readline().strip().split()))

def get_ints():
	return map(int, sys.stdin.readline().strip().split())

def input():
	return sys.stdin.readline().strip()
for t in range(int(input())):
	(n, k) = get_ints()
	a = get_array()
	cnt = 0
	ind = a.index(min(a))
	for i in range(n):
		if i != ind and a[i] < k:
			cnt += (k - a[i]) // a[ind]
	print(cnt)


for i in range(int(input())):
	(n, k) = tuple(map(int, input().split()))
	a = sorted([int(i) for i in input().split()])
	key = a[0]
	ans = 0
	for i in range(1, n):
		if a[i] < k:
			ans += (k - a[i]) // key
	print(ans)


def put():
	return map(int, input().split())
t = int(input())
for _ in range(t):
	(n, k) = put()
	l = list(put())
	m = min(l)
	ind = l.index(m)
	l.pop(ind)
	ans = 0
	for i in l:
		if k - i > 0:
			ans += (k - i) // m
	print(ans)


T = int(input())
for i in range(T):
	(n, k) = [int(i) for i in input().split()]
	arr = [int(i) for i in input().split()]
	arr.sort()
	suma = 0
	for i in range(1, len(arr)):
		suma += (k - arr[i]) // arr[0]
	print(suma)


def maxi(arr, k):
	arr.sort()
	count = 0
	for i in range(1, len(arr)):
		count = count + abs(k - arr[i]) // arr[0]
	return count
for i in range(int(input())):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	print(maxi(arr, k))


t = int(input())
for i in range(t):
	s = input()
	v = s.split()
	n = int(v[0])
	k = int(v[1])
	st = input()
	z = st.split()
	r = -1
	c = []
	while r < n - 1:
		r = r + 1
		m = int(z[r])
		c.append(m)
	min = c[0]
	j = -1
	while j < n - 1:
		j = j + 1
		if c[j] >= min:
			min = min
		else:
			min = c[j]
	sum = 0
	l = -1
	while l < n - 1:
		l = l + 1
		t = int((k - c[l]) / min)
		sum = sum + t
	print(sum - int((k - min) / min))


for i in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	m = min(a)
	count = 0
	f = 1
	for i in range(n):
		if f and a[i] == m:
			f = 0
			continue
		else:
			count += (k - a[i]) // m
	print(count)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	s = list(map(int, input().split()))
	s.sort()
	if s[0] + s[1] > k:
		print(0)
	else:
		s[1] += s[0]
		ans = 1
		for i in range(1, n):
			while s[i] <= k:
				s[i] += s[0]
				if s[i] <= k:
					ans += 1
		print(ans)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	arr.sort()
	count = 0
	for i in range(1, n):
		diff = k - arr[i]
		if diff > 0:
			count += diff // arr[0]
	print(count)


import sys

def main():
	T = int(input())
	for ti in range(T):
		(n, k) = map(int, input().split())
		A = sorted((int(a) for a in input().split()))
		a0 = A[0]
		ans = 0
		for (i, a) in enumerate(A):
			if i == 0:
				continue
			ans += (k - a) // a0
		print(ans)
main()


from sys import stdin, stdout
ans = []

def main():
	(n, k) = list(map(int, stdin.readline().split()))
	arr = list(map(int, stdin.readline().split()))
	minval = min(arr)
	count = 0
	for item in arr:
		count += int((k - item) / minval)
	count -= int((k - minval) / minval)
	ans.append(str(count))
for i in range(int(stdin.readline())):
	main()
stdout.write('\n'.join(ans))


t = int(input())
a = []
nk = []
count = 0
for i in range(t):
	nk.append(list(map(int, input().split())))
	a.append(list(map(int, input().split())))
for j in range(t):
	k = nk[j][1]
	n = nk[j][0]
	a[j].sort()
	for z in range(len(a[j]) - 1):
		b = (k - a[j][z + 1]) // a[j][0]
		count += b
	print(count)
	count = 0


import os
import heapq
import sys, threading
import math
import operator
from collections import defaultdict, deque
from io import BytesIO, IOBase
sys.setrecursionlimit(10 ** 5)

def gcd(a, b):
	if b == 0:
		return a
	else:
		return gcd(b, a % b)

def inpt():
	return [int(k) for k in input().split()]

def main():
	for _ in range(int(input())):
		(n, k) = inpt()
		ar = inpt()
		ar.sort()
		count = 0
		v = ar[0]
		ans = 0
		for i in range(1, n):
			ans += max(0, k - ar[i]) // v
		print(ans)
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
main()


q = int(input())
for _ in range(q):
	(n, k) = map(int, input().split())
	dat = map(int, input().split())
	dat = list(dat)
	dat.sort()
	x = dat[0]
	res = 0
	for i in range(1, n):
		diff = k - dat[i]
		res += diff // x
	print(res)


for case in range(int(input())):
	(N, K) = map(int, input().split())
	arr = list(map(int, input().split()))
	ix_min = 0
	minimo = min(arr)
	if minimo > K:
		print(0)
	else:
		sol = 0
		for i in range(N):
			if arr[i] == minimo:
				ix_min = i
				break
		for i in range(N):
			if i != ix_min:
				sol += (K - arr[i]) // minimo
		print(sol)


import sys
import os
from io import BytesIO, IOBase
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
mod = 10 ** 9 + 7

def lcm(x, y):
	return x * y / gcd(x, y)

def fact(x, mod=mod):
	ans = 1
	for i in range(1, x + 1):
		ans = ans * i % mod
	return ans

def arr2D(n, m, default=0):
	lst = []
	for i in range(n):
		temp = [default] * m
		lst.append(temp)
	return lst

def sortDictV(x):
	return {k: v for (k, v) in sorted(x.items(), key=lambda item: item[1])}

def solve(n, k, lst):
	minn = min(lst)
	val = []
	once = False
	for i in lst:
		if i == minn and (not once):
			once = True
			continue
		val.append(k - i)
	cnt = 0
	for i in val:
		cnt += i // minn
	return cnt
for _ in range(int(input())):
	(n, k) = list(map(int, input().split()))
	lst = list(map(int, input().split()))
	print(solve(n, k, lst))


for _ in range(int(input())):
	(N, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	min_ = min(arr)
	arr.remove(min_)
	count = 0
	for i in arr:
		count += (k - i) // min_
	print(count)


t = int(input())
ans = []
for i in range(t):
	a = []
	(n, k) = [int(i) for i in input().split()]
	a = [int(i) for i in input().split()]
	x = min(a)
	a.remove(x)
	count = 0
	for i in a:
		count += (k - i) // x
	ans.append(count)
for i in ans:
	print(i)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	mn = min(a)
	a.remove(mn)
	ans = 0
	for i in a:
		if i < k:
			ans += (k - i) // mn
	print(ans)


for _ in range(int(input())):
	(a, b) = list(map(int, input().split()))
	c = list(map(int, input().split()))
	c.sort()
	d = 0
	for i in c[1:]:
		d += (b - i) // c[0]
	print(d)


for q in range(int(input())):
	(n, k) = map(int, input().split())
	a = sorted(list(map(int, input().split())))
	res = 0
	for i in range(1, n):
		tmp = k - a[i]
		res += tmp // a[0]
	print(res)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	d = list(map(int, input().split()))
	d.sort()
	temp = []
	for i in range(1, len(d)):
		temp.append((k - d[i]) // d[0])
	print(sum(temp))


from sys import stdin, stdout
import math
import heapq
import collections
input = stdin.readline

def inputnum():
	return int(input())

def inputnums():
	return map(int, input().split())

def inputlist():
	return list(map(int, input().split()))

def inputstring():
	return [x for x in input()]

def inputstrings():
	return [x for x in input().split()]

def inputstringnum():
	return [ord(x) - ord('a') for x in input()]

def inputmatrixchar(rows):
	arr2d = [[j for j in input().strip()] for i in range(rows)]
	return arr2d

def inputmatrixint(rows):
	arr2d = []
	for _ in range(rows):
		arr2d.append([int(i) for i in input().split()])
	return arr2d
t = int(input())
for q in range(t):
	(n, k) = inputnums()
	a = inputlist()
	a.sort()
	ans = 0
	for i in range(1, n):
		ans += (k - a[i]) // a[0]
	print(ans)


import sys
from sys import stdin, stdout, setrecursionlimit
T = int(stdin.readline())
for _ in range(T):
	(n, k) = list(map(int, stdin.readline().rstrip().split()))
	a = list(map(int, stdin.readline().rstrip().split()))
	a.sort()
	ans = 0
	for i in range(1, n):
		if a[i] <= k:
			ans += (k - a[i]) // a[0]
	print(ans)


import itertools as it
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	counter = 0
	for i in range(1, len(a)):
		counter += (k - a[i]) // a[0]
	print(counter)


for _ in range(int(input())):
	(n, m) = map(int, input().split())
	arr = list(map(int, input().split()))
	mi = min(arr)
	if mi >= m:
		print(0)
	else:
		ans = 0
		f = 1
		for i in arr:
			if i == mi and f:
				f = 0
				continue
			ans += max(0, (m - i) // mi)
		print(ans)


a = int(input())
for x in range(a):
	(b, c) = map(int, input().split())
	d = list(map(int, input().split()))
	n = min(d)
	h = d.index(n)
	l = 0
	for y in range(b):
		if y == h:
			continue
		elif d[y] >= c:
			continue
		else:
			l += (c - d[y]) // n
	print(l)


def magic(k, piles):
	copy = 0
	mini = min(piles)
	t = piles.count(min(piles))
	if k - min(piles) > 0:
		for element in piles:
			if element != min(piles):
				if element < k:
					diff = k - element
					copy += diff // mini
			elif t > 1:
				if element <= k:
					diff = k - element
					copy += diff // mini
				t -= 1
		return copy
	else:
		return 0
number_cases = int(input())
for i in range(0, number_cases):
	number_piles = number_cases
	k = list(map(int, input().split()))[1]
	piles = list(map(int, input().split()))
	print(magic(k, piles))


t = int(input())
for T in range(t):
	(n, k) = map(int, input().split())
	min = 10 ** 4
	imin = 1
	a = [int(x) for x in input().split()]
	for i in range(n):
		if a[i] < min:
			min = a[i]
			imin = i
	ans = 0
	for i in range(n):
		if i != imin:
			ans += (k - a[i]) // min
	print(ans)


T = int(input())
for i in range(T):
	(n, k) = input().split(' ')
	n = int(n)
	k = int(k)
	a = [int(x) for x in input().split(' ')]
	a.sort()
	cont = 0
	b = a.copy()
	b[0] = a[0]
	b[1:] = [(k - x) // b[0] for x in a[1:]]
	s = sum(b[1:])
	print(s)


tt = int(input())
for j in range(tt):
	(n, k) = list(map(int, input().split()))
	arr = list(map(int, input().split()))
	arr.sort()
	ans = 0
	for i in range(1, len(arr)):
		if arr[i] > k:
			continue
		else:
			ans += (k - arr[i]) // arr[0]
	print(ans)


import sys
input = sys.stdin.readline
N = int(input())
for _ in range(N):
	num = 0
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	m = min(a)
	a.remove(m)
	for i in a:
		num += (k - i) // m
	print(num)


t = int(input(''))
for _ in range(t):
	[n, k] = list(map(int, input().split()))
	arr = list(map(int, input().split()))
	arr.sort()
	sol = 0
	for i in range(1, n):
		if arr[i] < k:
			a = k - arr[i]
			sol += a // arr[0]
	print(sol)


import os
import heapq
import sys, threading
import math
import bisect
import operator
from collections import defaultdict
sys.setrecursionlimit(10 ** 5)
from io import BytesIO, IOBase

def gcd(a, b):
	if b == 0:
		return a
	else:
		return gcd(b, a % b)

def power(x, p, m):
	res = 1
	while p:
		if p & 1:
			res = res * x % m
		x = x * x % m
		p >>= 1
	return res

def inar():
	return [int(k) for k in input().split()]

def lcm(num1, num2):
	return num1 * num2 // gcd(num1, num2)

def main():
	t = int(input())
	for _ in range(t):
		(n, k) = inar()
		arr = inar()
		ans = 0
		arr.sort()
		for i in range(1, n):
			ans += (k - arr[i]) // arr[0]
		print(ans)
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
main()


for t in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	b = sorted(a)
	x = b[0]
	cnt = 0
	for i in range(1, n):
		cnt += (k - b[i]) // x
	print(cnt, end='\n')


import os
from sys import stdin, stdout

class Input:

	def __init__(self):
		self.lines = stdin.readlines()
		self.idx = 0

	def line(self):
		try:
			return self.lines[self.idx].strip()
		finally:
			self.idx += 1

	def array(self, sep=' ', cast=int):
		return list(map(cast, self.line().split(sep=sep)))

	def known_tests(self):
		(num_of_cases,) = self.array()
		for case in range(num_of_cases):
			yield self

	def unknown_tests(self):
		while self.idx < len(self.lines):
			yield self

def problem_solver():

	def solver(inpt):
		(n, k) = inpt.array()
		a = inpt.array()
		a.sort()
		ans = 0
		for i in range(1, n):
			if a[i] >= k:
				break
			ans += (k - a[i]) // a[0]
		print(ans)
	return solver
try:
	solver = problem_solver()
	for tc in Input().known_tests():
		solver(tc)
except Exception as e:
	import traceback
	traceback.print_exc(file=stdout)


i = int(input())
ans = []
for _ in range(i):
	value = 0
	l = []
	k_mx = list(map(int, input().split()))
	l = list(map(int, input().split()))
	l = sorted(l)
	for s in l[1:]:
		value += (k_mx[1] - s) // l[0]
	ans += [value]
for a in ans:
	print(a)


from sys import stdin
input = stdin.readline

def A():
	t = int(input())
	for _ in range(t):
		(n, k) = map(int, input().split())
		a = sorted(list(map(int, input().split())))
		tot = 0
		for i in range(1, n):
			tot += (k - a[i]) // a[0]
		print(tot)
A()


from sys import stdin, stdout
import math, sys, heapq
from itertools import permutations, combinations
from collections import defaultdict, deque, OrderedDict
from os import path
import random
import bisect as bi

def yes():
	print('YES')

def no():
	print('NO')
if path.exists('input.txt'):
	sys.stdin = open('input.txt', 'r')
	sys.stdout = open('output.txt', 'w')

	def I():
		return int(input())

	def In():
		return map(int, input().split())
else:

	def I():
		return int(stdin.readline())

	def In():
		return map(int, stdin.readline().split())

def dict(a):
	d = {}
	for x in a:
		if d.get(x, -1) != -1:
			d[x] += 1
		else:
			d[x] = 1
	return d

def find_gt(a, x):
	i = bi.bisect_left(a, x)
	if i != len(a):
		return i
	else:
		return -1

def main():
	try:
		(n, k) = In()
		l = list(In())
		l.sort()
		ans = 0
		for x in range(1, n):
			if k >= l[x]:
				ans += (k - l[x]) // l[0]
		print(ans)
	except:
		pass
M = 998244353
P = 1000000007
for _ in range(I()):
	main()


T = int(input())
for t in range(T):
	(n, k) = [int(x) for x in input().split()]
	arr = [int(x) for x in input().split()]
	mine = min(arr)
	min_idx = arr.index(mine)
	add = []
	for i in range(n):
		if i != min_idx:
			cadd = int((k - arr[i]) / mine)
			add.append(cadd)
	max_op = sum(add)
	print(max_op)


t = int(input())
for _ in range(t):
	(n, k) = [int(x) for x in input().split()]
	l = list(map(int, input().split()))
	l.sort()
	cnt = 0
	for i in range(len(l)):
		j = i + 1
		while j < len(l):
			if l[i] + l[j] <= k:
				cnt += 1
				l[j] += l[i]
				continue
			else:
				j += 1
	print(cnt)


import sys
t = int(sys.stdin.readline().strip())
for t_idx in range(t):
	(n, k) = sys.stdin.readline().strip().split(' ')
	k = int(k)
	a_vec = sys.stdin.readline().strip().split(' ')
	res = 0
	min_a = int(a_vec[0])
	for a_val in a_vec:
		a_val = int(a_val)
		if a_val < min_a:
			min_a = a_val
	for a_val in a_vec:
		a_val = int(a_val)
		res = res + int((k - a_val) / min_a)
	res = res - int((k - min_a) / min_a)
	print(res)


def solve():
	(n, k) = [int(x) for x in input().split()]
	a = [int(x) for x in input().split()]
	a.sort()
	ans = 0
	for (i, x) in enumerate(a[1:]):
		m = (k - x) // a[0]
		ans += m
		a[i + 1] += m * a[0]
	ans += (k - a[0]) // a[1]
	return ans
T = int(input())
for case in range(T):
	print(solve())


T = int(input())
for _ in range(T):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	min_value = min(a)
	min_index = a.index(min_value)
	res = 0
	for i in range(n):
		if i != min_index and k > a[i]:
			res += (k - a[i]) // min_value
	print(res)


t = int(input())
for _ in range(t):
	(n, k) = list(map(int, input().split()))
	l = list(map(int, input().split()))
	l.sort()
	z = l[0]
	l.reverse()
	ans = 0
	for i in range(n - 1):
		ans += (k - l[i]) // z
	print(ans)


t = int(input())
for _ in range(t):
	sol = 0
	(n, k) = map(int, input().split())
	lst = list(map(int, input().split()))
	lst.sort()
	for idx in range(len(lst)):
		for to in range(len(lst) - 1, idx, -1):
			while lst[to] + lst[idx] <= k:
				lst[to] += lst[idx]
				sol += 1
	print(sol)


import sys
import itertools as it
import math as mt
import collections as cc
input = sys.stdin.readline
I = lambda : list(map(int, input().split()))
for tc in range(int(input())):
	(n, k) = I()
	l = I()
	x = min(l)
	y = l.index(x)
	ans = 0
	for i in range(n):
		if i != y:
			d = k - l[i]
			ans += d // x
	print(ans)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split(' '))
	arr = list(map(int, input().split(' ')))
	arr.sort()
	li = arr[1:]
	x = arr[0]
	res = 0
	for i in li:
		res += (k - i) // x
	print(res)


for i in range(int(input())):
	(n, k) = map(int, input().split())
	a = [int(e) for e in input().split()]
	x = min(a)
	z = 0
	for j in range(n):
		z += (k - a[j]) // x
	print(z - (k - x) // x)


def solve(n, k, A):
	min_value = min(A)
	ans_array = [0 for i in range(n)]
	for (i, pile) in enumerate(A):
		ans_array[i] = int((k - pile) / min_value)
	return sum(ans_array) - int((k - min_value) / min_value)
t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	A = list(map(int, input().split()))
	ans = solve(n, k, A)
	print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	x = list(map(int, input().split()))
	x.sort()
	cnt = 0
	for i in range(1, n):
		cnt += (k - x[i]) // x[0]
	print(cnt)


def solve(k):
	arr = list(map(int, input().split()))
	s = min(arr)
	arr.remove(s)
	c = 0
	for i in arr:
		c += (k - i) // s
	return c
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	print(solve(k))


import sys
ii = lambda : sys.stdin.readline().strip()
idata = lambda : [int(x) for x in ii().split()]

def solve():
	(n, k) = idata()
	data = sorted(idata())
	ans = 0
	for i in range(1, n):
		ans += (k - data[i]) // data[0]
	print(ans)
	return
for t in range(int(ii())):
	solve()


for t in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	ans = 0
	for i in range(len(a) - 1, -1, -1):
		x = a[i]
		j = 0
		while x <= k:
			if i != j:
				x += a[j]
				if x > k:
					x -= a[j]
					a[i] = x
					break
				else:
					ans += 1
			else:
				break
	print(ans)


t = int(input())
for _ in range(t):
	(n, k) = (int(i) for i in input().split())
	a = [int(i) for i in input().split()]
	m = min(a)
	idx = a.index(m)
	spell = 0
	for (i, e) in enumerate(a):
		if i == idx:
			continue
		if e >= k:
			continue
		spell += (k - e) // m
	print(spell)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	a = min(l)
	ans = 0
	for p in l:
		ans += (k - p) // a
	ans -= (k - a) // a
	print(ans)


import math
for t in range(int(input())):
	(n, k) = map(int, input().split())
	x = sorted(list(map(int, input().split())))
	if x[0] > k:
		print(0)
		continue
	mods = []
	ans = 0
	for i in range(1, n):
		ans += (k - x[i]) // x[0]
		mods += [(k - x[i]) % x[0]]
	print(ans)


import sys
sys.setrecursionlimit(2000)
from collections import Counter
from functools import reduce
t = [int(val) for val in sys.stdin.readline().split()][0]
for test in range(t):
	(n, k) = [int(val) for val in sys.stdin.readline().split()]
	a = [int(val) for val in sys.stdin.readline().split()]
	minn = [1000, None]
	for (ind, val) in enumerate(a):
		if val < minn[0]:
			minn = [val, ind]
	count = 0
	for (ind, val) in enumerate(a):
		if ind == minn[1]:
			pass
		else:
			diff = k - val
			count += diff // minn[0]
	print(count)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	brr = list(map(int, input().split()))
	m = min(brr)
	brr.remove(m)
	counts = 0
	for i in brr:
		if i < k:
			counts += (k - i) // m
	print(counts)


t = int(input())
v = []
for qwer in range(t):
	(n, k) = map(int, input().split())
	c = []
	ch = k
	s = 0
	for r in input().split():
		i = int(r)
		if i < ch:
			ch = i
			c = [i] + c
		else:
			c += [i]
	r = c[0]
	for i in c[1:]:
		s += (k - i) // r
	v += [s]
[print(i) for i in v]


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	list1 = [int(x) for x in input().split()]
	minVal = min(list1)
	ind = list1.index(minVal)
	total = 0
	temp = 0
	for i in range(len(list1)):
		if i != ind:
			temp = k - list1[i]
			temp //= minVal
			total += temp
	print(total)


for _ in range(int(input())):
	(m, n) = [*map(int, input().split())]
	l = [*map(int, input().split())]
	mini = min(l)
	ans = -int((n - mini) / mini)
	for el in l:
		ans += int((n - el) / mini)
	print(ans)


import sys
t = int(input())
for x in range(t):
	(n, k) = map(int, input().split(' '))
	A = list(map(int, input().split(' ')))
	min_index = None
	min_value = int(1000000000.0)
	for i in range(n):
		if A[i] < min_value:
			min_value = A[i]
			min_index = i
	ans = 0
	for i in range(n):
		if i != min_index:
			ans += (k - A[i]) // min_value
	print(ans)


t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	a1 = list(map(int, input().split()))
	mini = min(a1)
	ans = 0
	a1 = sorted(a1)
	for j in range(1, len(a1)):
		ans += (k - a1[j]) // mini
	print(ans)


t = int(input())
p = 1
while p <= t:
	(n, k) = input().split(' ')
	a = list(map(int, input().split(' ')))
	n = int(n)
	k = int(k)
	b = min(a)
	a.remove(b)
	i = 0
	sum = 0
	while i < n - 1:
		x = int((k - a[i]) / b)
		sum = sum + x
		i = i + 1
	print(int(sum))
	p = p + 1


import math
import os
import sys
from io import BytesIO, IOBase
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
t = int(input())
while t > 0:
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	arr.sort()
	count = 0
	temp = n - 1
	while temp > 0:
		if arr[temp] < k:
			if arr[temp] + arr[0] <= k:
				count += 1
				arr[temp] += arr[0]
			else:
				temp -= 1
		else:
			temp -= 1
	t -= 1
	print(count)


from collections import Counter, defaultdict
from sys import stdin, stdout
input = stdin.readline
I = lambda : int(input())
M = lambda : map(int, input().split())
LI = lambda : list(map(int, input().split()))
for _ in range(I()):
	(n, k) = M()
	a = LI()
	a.sort()
	b = a[0]
	ans = 0
	for i in range(1, n):
		while a[i] + b <= k:
			ans += 1
			a[i] += b
	print(ans)


t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	lst = list(map(int, input().split()))
	m = min(lst)
	lst.remove(m)
	c = 0
	for i in lst:
		if i < k:
			c += (k - i) // m
	print(c)


import sys
import bisect as bi
import math
from collections import defaultdict as dd
import heapq
import itertools
import io
import os
input = sys.stdin.readline
import random
mo = 10 ** 9 + 7

def cin():
	return map(int, sin().split())

def ain():
	return list(map(int, sin().split()))

def sin():
	return input()

def inin():
	return int(input())
for _ in range(inin()):
	(n, k) = cin()
	l = ain()
	l.sort()
	ans = 0
	for i in range(1, n):
		ans += (k - l[i]) // l[0]
	print(ans)


inp = lambda : int(input())
seq = lambda : list(map(int, input().strip().split()))

def results(arr, n, k):
	cnt = 0
	arr.sort()
	min_ = arr[0]
	for i in range(1, n):
		cnt += (k - arr[i]) // min_
	return cnt

def main():
	t = inp()
	for _ in range(t):
		nk = seq()
		(n, k) = (nk[0], nk[1])
		a = seq()
		result = results(a, n, k)
		print(result)
main()


test = int(input())
for t in range(test):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	m = min(a)
	ind = a.index(m)
	ans = 0
	for i in range(n):
		if i == ind:
			continue
		else:
			if a[i] > k:
				continue
			ans += (k - a[i]) // m
	print(ans)


for i in range(int(input())):
	(n, k) = map(int, input().split())
	li = list(map(int, input().split()))
	li.sort()
	s = 0
	for i in range(1, n):
		s += (k - li[i]) // li[0]
	print(s)


import sys
input = sys.stdin.readline

def prog():
	for _ in range(int(input())):
		(n, k) = map(int, input().split())
		a = list(map(int, input().split()))
		a.sort()
		tot = 0
		for i in range(1, n):
			tot += (k - a[i]) // a[0]
		print(tot)
prog()


for T in range(int(input())):
	(N, K) = map(int, input().split())
	nums = list(map(int, input().split()))
	nums.sort()
	low = nums[0]
	ptr = 0
	for i in range(1, len(nums)):
		ptr += (K - nums[i]) // low
	print(ptr)


for tt in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	ans = 0
	mn = min(l)
	idx = l.index(mn)
	for i in range(n):
		if i != idx:
			ans += (k - l[i]) // mn
	print(ans)


def solver(x, k):
	min_el = min(x)
	idx_min_el = x.index(min_el)
	total = 0
	for i in range(len(x)):
		if i == idx_min_el:
			continue
		total += (k - x[i]) // min_el
	return str(total)
t = int(input())
ans = []
for i in range(t):
	(_, k) = list(map(int, input().split()))
	x = list(map(int, input().split()))
	answer = solver(x, k)
	ans.append(answer)
print('\n'.join(ans))


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	a = min(l)
	l.remove(a)
	print((sum(((k - i) // a for i in l)), 0)[max(l) > k])


import sys
from collections import defaultdict as dc
import math
from bisect import bisect, bisect_left, bisect_right
input = sys.stdin.readline
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	l = sorted(list(map(int, input().split())))
	x = l[0]
	c = 0
	f = 0
	for i in range(1, n):
		if l[i] > k:
			c = 0
			break
		c += (k - l[i]) // x
	print(c)


from sys import stdin
TT = int(stdin.readline())
for loop in range(TT):
	(n, k) = map(int, stdin.readline().split())
	a = list(map(int, stdin.readline().split()))
	ans = 0
	a.sort()
	for i in range(1, n):
		ans += (k - a[i]) // a[0]
	print(ans)


n = int(input())
for _ in range(n):
	(x, y) = [int(i) for i in input().split()]
	l = [int(i) for i in input().split()]
	ans = 0
	l.sort()
	for k in range(x - 1, 0, -1):
		ans = ans + (y - l[k]) // l[0]
	print(ans)


t = int(input())
while t > 0:
	t -= 1
	(n, k) = [int(x) for x in input().split()]
	x = [int(x) for x in input().split()]
	x.sort()
	count = 0
	for i in range(1, n):
		while x[i] + x[0] <= k:
			x[i] += x[0]
			count += 1
	print(count)


def solve():
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	c = 0
	for i in range(1, n):
		c += (k - a[i]) // a[0]
	print(c)
t = int(input())
i = 0
while i < t:
	solve()
	i += 1


def proA(arr, k):
	arr.sort()
	ans = 0
	for i in range(1, len(arr)):
		ans += (k - arr[i]) // arr[0]
	return ans
t = int(input())
for i in range(t):
	arr = list(map(int, input().split()))
	(n, k) = arr
	arr = list(map(int, input().split()))
	print(proA(arr, k))


t = int(input())
while t:
	t -= 1
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	l.sort()
	ans = 0
	num = l[0]
	i = 1
	while i < n:
		ans += max((k - l[i]) // num, 0)
		i += 1
	print(ans)


from sys import stdin, stdout, setrecursionlimit
import heapq
from math import gcd, ceil, sqrt
from collections import Counter, deque
from bisect import bisect_left, bisect_right
from itertools import combinations, permutations
ii1 = lambda : int(stdin.readline().strip())
is1 = lambda : stdin.readline().strip()
iia = lambda : list(map(int, stdin.readline().strip().split()))
isa = lambda : stdin.readline().strip().split()
setrecursionlimit(100000)
mod = 1000000007
tc = ii1()
for _ in range(tc):
	(n, k) = iia()
	arr = sorted(iia())
	cnt = 0
	for i in range(1, len(arr)):
		if arr[i] > k:
			cnt = 0
			break
		else:
			cnt += (k - arr[i]) // arr[0]
	print(cnt)


import sys
reader = (s.rstrip() for s in sys.stdin)
input = reader.__next__

def gift():
	for _ in range(t):
		(n, k) = list(map(int, input().split()))
		array = list(map(int, input().split()))
		minItem = min(array)
		met = False
		minRes = 0
		for i in range(n):
			if array[i] == minItem:
				if met == False:
					met = True
					continue
			minRes += (k - array[i]) // minItem
		yield minRes
t = int(input())
ans = gift()
print(*ans, sep='\n')


R = lambda : map(int, input().split())
(t,) = R()
for _ in [0] * t:
	(n, k) = R()
	(*a,) = R()
	d = a[0]
	i = 0
	while d >= a[0]:
		a.sort()
		d = k - a[1]
		a[1] = k - d % a[0]
		i += d // a[0]
	print(i)


def main():
	for i in range(int(input())):
		(n, k) = input().split()
		n = int(n)
		k = int(k)
		arr = list(map(int, input().split()))
		arr.sort()
		ans = 0
		for i in range(1, n):
			if k <= arr[i]:
				continue
			else:
				ans += (k - arr[i]) // arr[0]
		print(ans)
main()


t = int(input())
while t:
	t -= 1
	(n, k) = map(int, input().split())
	lst = list(map(int, input().split()))
	lst.sort()
	sum1 = 0
	for i in range(1, n):
		if lst[i] < k:
			sum1 += (k - lst[i]) // lst[0]
	print(sum1)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	minimum = min(a)
	res = 0
	for i in a:
		if k > i:
			res = res + (k - i) // minimum
	if k > minimum:
		res = res - (k - minimum) // minimum
	print(res)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	ls = list(map(int, input().split()))
	_min = min(ls)
	ls.remove(_min)
	count = 0
	for i in range(n - 1):
		count += int((k - ls[i]) // _min)
	print(count)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	m = min(arr)
	cc = 0
	s = 0
	for i in range(n):
		if arr[i] == m and cc == 0:
			cc = 1
			continue
		if arr[i] != m or cc != 0:
			s += (k - arr[i]) // m
	print(s)


for _ in range(int(input())):
	(n, k) = [int(c) for c in input().split()]
	arr = [int(c) for c in input().split()]
	arr.sort()
	ls = arr[0]
	arr = arr[1:]
	count = 0
	for i in arr[::-1]:
		diff = k - i
		if diff > 0:
			count += diff // ls
	print(count)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	m = min(arr)
	out = 0
	for i in arr:
		out += (k - i) // m
	out -= (k - m) // m
	print(out)


for i in range(int(input())):
	(a, b) = list(map(int, input().split()))
	c = sorted(list(map(int, input().split())))
	print(sum(((b - c[i]) // c[0] for i in range(1, a))))


n = int(input())
for i in range(n):
	(a, b) = [int(i) for i in input().split()]
	c = [int(i) for i in input().split()]
	c = sorted(c)
	sum = 0
	d = min(c)
	for j in range(1, len(c)):
		sum = sum + (b - c[j]) // d
	print(sum)


def solve(N, K, candyPiles):
	candyPiles.sort()
	minimum = candyPiles[0]
	res = 0
	for i in range(1, N):
		if candyPiles[i] < K:
			res += (K - candyPiles[i]) // minimum
	print(res)
for _ in range(int(input())):
	(N, K) = map(int, input().split())
	candyPiles = list(map(int, input().split()))
	solve(N, K, candyPiles)


from bisect import *
from collections import *
from math import gcd, ceil, sqrt, floor, inf
from heapq import *
from typing import List
from itertools import *
from operator import add, mul, sub, xor, truediv, floordiv
from functools import *
import os
import sys
from io import BytesIO, IOBase
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')

def RL():
	return map(int, sys.stdin.readline().rstrip().split())

def RLL():
	return list(map(int, sys.stdin.readline().rstrip().split()))

def N():
	return int(input())

@lru_cache(None)
def fact(x, mod=0):
	if x < 2:
		return 1
	if not mod:
		return fact(x - 1) * x
	return fact(x - 1, mod) * x % mod

@lru_cache(None)
def per(i, j, mod=0):
	if i < j:
		return 0
	if not mod:
		return fact(i) // fact(i - j)
	ans = 1
	for k in range(i - j + 1, i + 1):
		ans = ans * k % mod
	return ans

@lru_cache(None)
def com(i, j, mod=0):
	if i < j:
		return 0
	if not mod:
		return per(i, j) // fact(j)
	return per(i, j) * inverse(fact(j), mod) % mod

def catalan(n):
	return com(2 * n, n) // (n + 1)

def linc(f, t, l, r):
	while l < r:
		mid = (l + r) // 2
		if t > f(mid):
			l = mid + 1
		else:
			r = mid
	return l

def rinc(f, t, l, r):
	while l < r:
		mid = (l + r + 1) // 2
		if t < f(mid):
			r = mid - 1
		else:
			l = mid
	return l

def ldec(f, t, l, r):
	while l < r:
		mid = (l + r) // 2
		if t < f(mid):
			l = mid + 1
		else:
			r = mid
	return l

def rdec(f, t, l, r):
	while l < r:
		mid = (l + r + 1) // 2
		if t > f(mid):
			r = mid - 1
		else:
			l = mid
	return l

def isprime(n):
	for i in range(2, int(n ** 0.5) + 1):
		if n % i == 0:
			return False
	return True

def binfun(x):
	c = 0
	for w in arr:
		c += ceil(w / x)
	return c

def lowbit(n):
	return n & -n

def inverse(a, m):
	a %= m
	if a <= 1:
		return a
	return (1 - inverse(m, a) * m) // a % m

class BIT:

	def __init__(self, arr):
		self.arr = arr
		self.n = len(arr) - 1

	def update(self, x, v):
		while x <= self.n:
			self.arr[x] += v
			x += x & -x

	def query(self, x):
		ans = 0
		while x:
			ans += self.arr[x]
			x &= x - 1
		return ans

class smt:

	def __init__(self, l, r, arr):
		self.l = l
		self.r = r
		self.value = (1 << 31) - 1 if l < r else arr[l]
		mid = (l + r) // 2
		if l < r:
			self.left = smt(l, mid, arr)
			self.right = smt(mid + 1, r, arr)
			self.value &= self.left.value & self.right.value

	def setvalue(self, x, val):
		if self.l == self.r:
			self.value = val
			return
		mid = (self.l + self.r) // 2
		if x <= mid:
			self.left.setvalue(x, val)
		else:
			self.right.setvalue(x, val)
		self.value = self.left.value & self.right.value

	def ask(self, l, r):
		if l <= self.l and r >= self.r:
			return self.value
		val = (1 << 31) - 1
		mid = (self.l + self.r) // 2
		if l <= mid:
			val &= self.left.ask(l, r)
		if r > mid:
			val &= self.right.ask(l, r)
		return val

class DSU:

	def __init__(self, n):
		self.c = [-1] * n

	def same(self, x, y):
		return self.find(x) == self.find(y)

	def find(self, x):
		if self.c[x] < 0:
			return x
		self.c[x] = self.find(self.c[x])
		return self.c[x]

	def union(self, u, v):
		(u, v) = (self.find(u), self.find(v))
		if u == v:
			return False
		if self.c[u] < self.c[v]:
			(u, v) = (v, u)
		self.c[u] += self.c[v]
		self.c[v] = u
		return True

	def size(self, x):
		return -self.c[self.find(x)]

class UFS:

	def __init__(self, n):
		self.parent = [i for i in range(n)]
		self.ranks = [0] * n

	def find(self, x):
		if x != self.parent[x]:
			self.parent[x] = self.find(self.parent[x])
		return self.parent[x]

	def union(self, u, v):
		(pu, pv) = (self.find(u), self.find(v))
		if pu == pv:
			return False
		if self.ranks[pu] >= self.ranks[pv]:
			self.parent[pv] = pu
			if self.ranks[pv] == self.ranks[pu]:
				self.ranks[pu] += 1
		else:
			self.parent[pu] = pv

def Prime(n):
	c = 0
	prime = []
	flag = [0] * (n + 1)
	for i in range(2, n + 1):
		if not flag[i]:
			prime.append(i)
			c += 1
		for j in range(c):
			if i * prime[j] > n:
				break
			flag[i * prime[j]] = prime[j]
			if i % prime[j] == 0:
				break
	return prime

def dij(s, graph):
	d = {}
	d[s] = 0
	heap = [(0, s)]
	seen = set()
	while heap:
		(dis, u) = heappop(heap)
		if u in seen:
			continue
		for v in graph[u]:
			if v not in d or d[v] > d[u] + graph[u][v]:
				d[v] = d[u] + graph[u][v]
				heappush(heap, (d[v], v))
	return d
t = N()
for i in range(t):
	(n, k) = RL()
	a = RLL()
	a.sort()
	mi = a[0]
	ans = 0
	for i in range(1, n):
		ans += (k - a[i]) // mi
	print(ans)


t = int(input())
for test in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	smallest = min(a)
	smallest_idx = a.index(smallest)
	count = 0
	for i in range(n):
		if i == smallest_idx:
			continue
		hight = a[i]
		diff = k - hight
		count += int(diff / smallest)
	print(count)


for _ in range(int(input())):
	(n, k) = [int(x) for x in input().split()]
	arrs = sorted([int(x) for x in input().split()])
	mins = arrs[0]
	counts = sum([(k - x) // mins for x in arrs[1:]])
	print(counts)


from sys import stdin
input = stdin.readline
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = [*map(int, input().split())]
	ma = min(a)
	for i in range(n):
		if a[i] == ma:
			a[i] = k
			break
	print(sum(((k - i) // ma for i in a)))


import os
import sys
from math import *
from collections import *
from bisect import *
from io import BytesIO, IOBase

def vsInput():
	sys.stdin = open('input.txt', 'r')
	sys.stdout = open('output.txt', 'w')
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
ALPHA = 'abcdefghijklmnopqrstuvwxyz/'
M = 998244353
EPS = 1e-06

def Ceil(a, b):
	return a // b + int(a % b > 0)

def value():
	return tuple(map(int, input().split()))

def array():
	return [int(i) for i in input().split()]

def Int():
	return int(input())

def Str():
	return input()

def arrayS():
	return [i for i in input().split()]
for _ in range(Int()):
	(n, k) = value()
	a = sorted(array())
	key = a[0]
	ans = 0
	for i in range(1, n):
		if a[i] < k:
			ans += (k - a[i]) // key
	print(ans)


t = int(input())
for _ in range(t):
	(n, k) = list(map(int, input().split()))
	a = list(map(int, input().split()))
	total = 0
	x = min(a)
	argmin = a.index(x)
	for (ind, i) in enumerate(a):
		if ind == argmin:
			continue
		total += (k - i) // x
		if i > k:
			total = 0
			break
	print(total)


import math
T = int(input())
for i in range(T):
	(n, k) = input().split()
	n = int(n)
	k = int(k)
	magic = 0
	list_a = input().split()
	for q in range(len(list_a)):
		temp = int(list_a[q])
		list_a[q] = temp
	list_a.sort()
	sit = True
	all_iterate = 0
	for j in reversed(range(len(list_a))):
		if j != 0:
			temp2 = math.floor((k - list_a[j]) / list_a[0]) - all_iterate
			all_iterate += temp2
			magic += temp2 * j
	print(magic)


testcase = int(input())
while testcase:
	(n, k) = map(int, input().split())
	N = sorted(list(map(int, input().split())))
	a = N[0]
	count = 0
	for ind in range(1, len(N)):
		if N[ind] > k:
			continue
		count += int((k - N[ind]) / a)
	print(count)
	testcase -= 1


for t in range(int(input())):
	(n, k) = tuple(map(int, input().split()))
	a = list(map(int, input().split()))
	m = min(a)
	a = sorted(a)
	t = 0
	for i in range(1, n):
		if a[i] < k:
			t += (k - a[i]) // m
	print(t)


import math

def range_input():
	return range(int(input()))

def map_int_input():
	return list(map(int, input().split()))
for t in range_input():
	(n, k) = map_int_input()
	a = map_int_input()
	a.sort()
	count = 0
	min_val = a[0]
	for i in range(1, n):
		temp = (k - a[i]) // min_val
		count += temp
	print(count)


for _ in range(int(input())):
	(n, MAX) = map(int, input().split())
	l = list(map(int, input().split()))
	l.sort()
	ans = 0
	for i in range(1, n):
		ans += (MAX - l[i]) // l[0]
	print(ans)


for x in range(int(input())):
	(a, b) = map(int, input().split())
	l = sorted(list(map(int, input().split())))
	c = l[0]
	res = []
	i = 0
	for y in range(1, a):
		if l[y] > b:
			break
		m = b - l[y]
		i = m // c
		res.append(i)
	print(sum(res))


t = int(input())
for _ in range(t):
	(n, k) = list(map(int, input().split()))
	arr = list(map(int, input().split()))
	arr.sort()
	num = []
	for i in range(1, n):
		num.append(k - arr[i])
	ans = 0
	for i in range(n - 1):
		ans += num[i] // arr[0]
	print(ans)


(T,) = map(int, input().split())
for _ in range(T):
	(N, K) = map(int, input().split())
	X = list(map(int, input().split()))
	X.sort()
	X = X[::-1]
	m = X.pop()
	R = 0
	for x in X:
		R += (K - x) // m
	else:
		print(R)


from functools import reduce
import os
import sys
from collections import *
from math import *
from bisect import *
from heapq import *
from io import BytesIO, IOBase
input = lambda : sys.stdin.readline().rstrip('\r\n')

def value():
	return tuple(map(int, input().split()))

def arr():
	return [int(i) for i in input().split()]

def sarr():
	return [int(i) for i in input()]

def starr():
	return [str(x) for x in input().split()]

def inn():
	return int(input())

def svalue():
	return tuple(map(str, input().split()))

def parr():
	return [value() for i in range(n)]
mo = 1000000007
inf = 1e+18
div = 998244353
for _ in range(inn()):
	(n, k) = value()
	a = arr()
	a.sort()
	ans = 0
	for i in range(1, n):
		res = k - a[i]
		ans += res // a[0]
	print(ans)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	arr = [int(x) for x in input().split()]
	m = min(arr)
	ans = 0
	for i in arr:
		ans += (k - i) // m
	print(ans - (k - m) // m)


testcases = int(input())
while testcases:
	(size, limit) = map(int, input().split())
	array = list(map(int, input().split()))
	array = sorted(array)
	finalval = 0
	for i in range(1, len(array)):
		if array[i] >= limit:
			break
		val = limit - array[i]
		result = val // array[0]
		finalval += result
	print(finalval)
	testcases -= 1


from math import floor
t = int(input())
while t:
	t -= 1
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	d = dict()
	for i in l:
		if i in d:
			d[i] += 1
		else:
			d[i] = 1
	ans = 0
	for i in d:
		curr = 0
		for j in d:
			if j == i:
				temp = d[j] - 1
			else:
				temp = d[j]
			curr += floor((k - j) // i) * temp
		ans = max(ans, curr)
	print(ans)


def testCase():
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	minValue = 10000000.0
	minIndex = -1
	for i in range(n):
		if a[i] < minValue:
			minValue = a[i]
			minIndex = i
	ans = 0
	for i in range(n):
		if i == minIndex:
			continue
		val = k - a[i]
		ans += val // minValue
	print('{}'.format(ans))
test = int(input())
while test:
	test -= 1
	testCase()


def solve(A, N, K):
	B = []
	for a in A:
		if a < K:
			B.append(a)
	B.sort()
	res = 0
	for i in range(len(B) - 1, 0, -1):
		res += (K - B[i]) // B[0]
	return res
t = int(input())
res = []
while t:
	line = input().split()
	N = int(line[0])
	K = int(line[1])
	A = [int(n) for n in input().split()]
	res.append(solve(A, N, K))
	t -= 1
for r in res:
	print(r)


import sys
import heapq, functools, collections
import math, random
from collections import Counter, defaultdict

def solve(arr, k):
	console('----- solving ------')
	arr = sorted(arr)
	res = 0
	curmin = 10 ** 10
	for a in arr[1:]:
		res += (k - a) // arr[0]
		curmin = min(curmin, a + (k - a) * arr[0])
	if arr[0] + curmin <= k:
		res += 1
	return res

def console(*args):
	return
for case_num in range(int(input())):
	(_, k) = list(map(int, input().split()))
	lst = list(map(int, input().split()))
	res = solve(lst, k)
	print(res)


x = int(input())
a = []
for i in range(x):
	(n, k) = map(int, input().split())
	s = list(map(int, input().split()))
	i = 0
	s.sort()
	for j in range(1, n):
		if s[j] != k:
			i += (k - s[j]) // s[0]
	a.append(i)
for row in a:
	print(row)


def solve(a, n, k):
	minimum = min(a)
	index = a.index(minimum)
	count = 0
	for (i, v) in enumerate(a):
		if i != index:
			if v < k and k - v >= minimum:
				number = (k - v) // minimum
				count += number
	print(count)
T = int(input())
for _ in range(T):
	(n, k) = list(map(int, input().split(' ')))
	a = list(map(int, input().split(' ')))
	solve(a, n, k)


t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	l.sort()
	i = 0
	rs = 0
	for i in range(len(l)):
		if i == 0:
			continue
		if l[0] + l[i] <= k:
			l[i] += l[0]
			rs += 1
			while l[i] + l[0] <= k:
				l[i] += l[0]
				rs += 1
	print(rs)


t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	sum = 0
	mn = k + 1
	mini = -1
	for i in range(n):
		if a[i] < mn:
			mn = a[i]
			mini = i
	for i in range(n):
		if i != mini:
			sum += (k - a[i]) // mn
	print(sum)


import math
t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	ali = list(map(int, input().split()))
	ali.sort()
	q = ali[0]
	cnt = 0
	for i in range(1, n):
		if ali[i] < k:
			e = (k - ali[i]) // q
			cnt = cnt + e
	print(cnt)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	i = 1
	m = 0
	l.sort()
	mi = l[0]
	while i < n:
		m += (k - l[i]) // mi
		i += 1
	print(m)


from sys import stdin, stdout

def gmi():
	return map(int, stdin.readline().strip().split())

def gms():
	return map(str, stdin.readline().strip().split())

def gari():
	return list(map(int, stdin.readline().strip().split()))

def gars():
	return list(map(int, stdin.readline().strip().split()))

def gs():
	return stdin.readline().strip()

def gls():
	return list(stdin.readline())

def gi():
	return int(stdin.readline())
t = gi()
while t:
	t -= 1
	(n, k) = gmi()
	ar = sorted(gari())
	ans = 0
	l = n
	m = ar[0]
	while l != 1:
		for i in range(1, l):
			v = ar[i]
			if v + m > k:
				l = i
				break
			ar[i] = v + v * ((k - v) // m)
			ans += (k - v) // m
	print(ans)


e = int(input())
for j in range(e):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	t = 0
	ans = 0
	m = min(l)
	for i in l:
		if t or i != m:
			ans += (k - i) // m
		else:
			t = 1
	print(ans)


import math
t = int(input())
for i in range(t):
	a = list(map(int, input().split(' ')))
	n = a[0]
	k = a[1]
	a = list(map(int, input().split(' ')))
	a.sort()
	d = 0
	for i in range(1, n):
		if k > a[i]:
			d += (k - a[i]) // a[0]
	print(d)


for i in range(int(input())):
	(n, k) = [int(num) for num in input().split()]
	x = list(map(int, input().split()))
	lst = list()
	count = 0
	c = min(x)
	x.remove(c)
	if c > k:
		print(0)
		continue
	for i in range(n - 1):
		if x[i] <= k:
			count = count + (k - x[i]) // c
	print(count)


import sys
input = sys.stdin.readline
I = lambda : list(map(int, input().split()))
(t,) = I()
for _ in range(t):
	(n, k) = I()
	l = I()
	an = 0
	r = min(l)
	f = 1
	for i in range(n):
		if f and l[i] == r:
			f = 0
			continue
		an += (k - l[i]) // r
	print(an)


import sys
from math import *
from functools import *
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	j = a.index(min(a))
	ans = 0
	for i in range(n):
		if i != j:
			ans += (k - a[i]) // a[j]
	print(ans)


import math
from sys import stdin, stdout
ip = lambda : int(stdin.readline())
inp = lambda : map(int, stdin.readline().split())
ips = lambda : stdin.readline().rstrip()
out = lambda x: stdout.write(str(x) + '\n')

def qpow(a, b, m):
	ans = 1
	while b:
		if b & 1:
			ans *= a
			ans %= m
		a *= a
		a %= m
		b >>= 1
	return ans
T = ip()
for _ in range(T):
	(n, k) = inp()
	a = list(inp())
	a.sort()
	ans = 0
	for i in range(1, n):
		ans += (k - a[i]) // a[0]
	out(ans)


t = int(input())
for i in range(t):
	(n, k) = input().strip().split(' ')
	(n, k) = [int(n), int(k)]
	a = list(map(int, input().strip().split(' ')))
	a.sort()
	p = a[0]
	ans = 0
	for j in range(1, n):
		xx = k - a[j]
		if xx < 0:
			break
		else:
			ans += xx // p
	print(ans)


def copy_paste(arr, k):
	m = min(arr)
	arr.remove(m)
	count = 0
	for i in arr:
		d = k - i
		count += d // m
	return count
t = int(input())
for _ in range(t):
	nk = input().split()
	n = int(nk[0])
	k = int(nk[1])
	arr = list(map(int, input().split()))
	print(copy_paste(arr, k))


rn = lambda : int(input())
rl = lambda : list(map(int, input().split()))
rns = lambda : map(int, input().split())
rs = lambda : input()
yn = lambda x: print('Yes') if x else print('No')
for _ in range(rn()):
	(n, k) = rns()
	l = rl()
	l.sort()
	ans = 0
	for i in range(1, n):
		a = k - l[i]
		ans += a // l[0]
	print(ans)


from sys import *
from collections import defaultdict as dd
from math import *
from bisect import *

def sinp():
	return input()

def inp():
	return int(sinp())

def minp():
	return map(int, sinp().split())

def linp():
	return list(minp())

def strl():
	return list(sinp())

def pr(x):
	print(x)
mod = int(1000000000.0 + 7)
for _ in range(inp()):
	(n, k) = minp()
	a = linp()
	a.sort()
	res = 0
	for i in range(1, n):
		res += (k - a[i]) // a[0]
	pr(res)


for i in range(int(input())):
	answer = 0
	v = list(map(int, input().split()))
	x = sorted(list(map(int, input().split())))
	for j in x[1:]:
		if j < v[1]:
			answer += (v[1] - j) // x[0]
	print(answer)


import sys
for _ in range(int(input())):
	(n, k) = map(int, sys.stdin.readline().strip().split())
	a = list(map(int, sys.stdin.readline().strip().split()))
	count = 0
	m = min(a)
	i = a.index(m)
	for j in range(n):
		if j != i and a[j] < k:
			count += (k - a[j]) // m
	print(count)


q = int(input())
for _ in range(q):
	(n, d) = map(int, input().split())
	arr = list(map(int, input().split()))
	arr.sort()
	c = 0
	for i in range(1, n):
		c = c + (d - arr[i]) // arr[0]
	print(c)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	m = min(a)
	mi = a.index(m)
	total = 0
	for (i, x) in enumerate(a):
		if i == mi:
			continue
		total += (k - x) // m
	print(total)


t = int(input())
for tc in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	ans = 0
	a.sort()
	if max(a) <= k:
		for i in range(1, n):
			diff = k - a[i]
			ans += diff // a[0]
	print(ans)


def ans(n, k, seq):
	mini = min(seq)
	cnt = 0
	res = 0
	for i in seq:
		if i != mini:
			res += (k - i) // mini
		else:
			cnt += 1
	cnt -= 1
	res += (k - mini) // mini * cnt
	print(res)
t = int(input())
for i in range(t):
	(h, h1) = map(int, input().split())
	hs = list(map(int, input().split()))
	ans(h, h1, hs)


t = int(input())
while t:
	l = [int(i) for i in input().split()]
	l1 = [int(i) for i in input().split()]
	n = l[0]
	k = l[1]
	s = min(l1)
	l1.remove(s)
	c = 0
	for ii in range(n - 1):
		y = k - l1[ii]
		y = y / s
		c = c + int(y)
	print(c)
	t -= 1


for _ in range(int(input())):
	(n, x) = map(int, input().split())
	a = sorted(map(int, input().split()))
	ans = 0
	for i in range(1, n):
		ans += (x - a[i]) // a[0]
	print(ans)


import math
t = int(input())
while t:
	t -= 1
	(n, k) = input().split(' ')
	n = int(n)
	k = int(k)
	arr = [int(x) for x in input().split(' ')]
	ans = 0
	minn = min(arr)
	if minn > k:
		print('0')
		continue
	flag = 1
	for i in arr:
		if i > k:
			continue
		if i == minn and flag:
			flag = 0
			continue
		ans += math.floor((k - i) / minn)
	print(ans)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	min_index = 0
	for i in range(n):
		if arr[i] < arr[min_index]:
			min_index = i
	result = 0
	for i in range(n):
		if i != min_index:
			result += (k - arr[i]) // arr[min_index]
	print(result)


t = int(input())
for i in range(0, t):
	v = 0
	(n, k) = input().split()
	n = int(n)
	k = int(k)
	a = list(map(int, input().split()))
	a.sort()
	b = list()
	for j in range(1, n):
		b.append((k - a[j]) // a[0])
	print(sum(b))


import sys
import math
input = lambda : sys.stdin.readline().rstrip()
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	l = [int(x) for x in input().split()]
	l.sort()
	a = 0
	for i in range(1, n):
		if l[i] >= k:
			break
		else:
			a += (k - l[i]) // l[0]
	print(a)


t = int(input())
for i in range(t):
	(n, k) = [int(j) for j in input().split()]
	a = [int(j) for j in input().split()]
	m = min(a)
	s = 0
	for j in range(n):
		s += (k - a[j]) // m
	print(s - (k - m) // m)


for __ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	val = min(a)
	(sum, c) = (0, 0)
	for i in a:
		if i == val and c == 0:
			c += 1
			continue
		if i > k:
			continue
		elif k > i:
			sum += (k - i) // val
	print(sum)


t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	s = min(a)
	d = 0
	f = 0
	for i in range(len(a)):
		if s == a[i] and d == 0:
			d += 1
			continue
		else:
			f += (k - a[i]) // s
	print(f)


T = int(input())
for _ in range(T):
	(n, k) = map(int, input().split())
	a = map(int, input().split())
	a = sorted(a)
	ans = 0
	for it in a[1:]:
		ans += (k - it) // a[0]
	print(ans)


t = int(input())
while t > 0:
	t -= 1
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	l.sort()
	m = min(l)
	cnt = 0
	for i in range(1, n):
		cnt += int((k - l[i]) / m)
	print(cnt)


from collections import defaultdict as D
from sys import stdin, stdout
for _ in range(int(stdin.readline())):
	(n, k) = map(int, stdin.readline().strip().split())
	a = list(map(int, stdin.readline().strip().split()))
	a.sort()
	ans = 0
	for i in range(1, n):
		ans += (k - a[i]) // a[0]
	print(ans)


import sys
input = sys.stdin.readline

def solve():
	(n, k) = list(map(int, input().split()))
	a = sorted(list(map(int, input().split())))
	ans = 0
	m = a[0]
	for i in a[1:]:
		ans += (k - i) // m
	print(ans)
t = int(input())
for _ in range(t):
	solve()


import sys
input = sys.stdin.readline
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	ar = list(map(int, input().split()))
	ar.sort()
	ans = 0
	for i in range(1, n):
		ans += max(k - ar[i], 0) // ar[0]
	print(ans)


import sys
read = lambda : sys.stdin.readline().strip()
readi = lambda : map(int, read().split())
for _ in range(int(read())):
	(n, k) = readi()
	nums = list(readi())
	nums.sort()
	ans = 0
	m = nums[0]
	for i in nums[1:]:
		ans += (k - i) // m
	print(ans)


import os
import sys
from io import BytesIO, IOBase
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')

def RL():
	return map(int, sys.stdin.readline().rstrip().split())

def RLL():
	return list(map(int, sys.stdin.readline().rstrip().split()))

def N():
	return int(input())

def print_list(l):
	print(' '.join(map(str, l)))
for _ in range(N()):
	(n, k) = RL()
	a = RLL()
	key = min(a)
	res = 0
	for i in a:
		res += (k - i) // key
	print(res - k // key + 1)


N = int(input())
for _ in range(N):
	A = list(map(int, input().split()))
	B = sorted(list(map(int, input().split())))
	ans = 0
	for i in range(1, A[0]):
		ans += int((A[1] - B[i]) // B[0])
	print(ans)


s = ''
for i in range(int(input())):
	(n, k) = map(int, input().split())
	a = sorted([int(i) for i in input().split()])
	c = 0
	for j in range(1, n):
		c += int((k - a[j]) / a[0])
	s = s + str(c) + '\n'
print(s)


import sys

def solution():
	get_input = sys.stdin.readline
	t = int(get_input().strip())
	for i in range(t):
		(n, k) = list(map(int, get_input().strip().split()))
		board = list(map(int, get_input().strip().split()))
		board.sort()
		mb = board[0]
		total = 0
		for j in range(1, n):
			total += (k - board[j]) // mb
		print(total)
solution()


from __future__ import division, print_function
import os, sys
from io import BytesIO, IOBase
if sys.version_info[0] < 3:
	from __builtin__ import xrange as range
	from future_builtins import ascii, filter, hex, map, oct, zip

def ii():
	return int(input())

def si():
	return input()

def mi():
	return map(int, input().strip().split(' '))

def msi():
	return map(str, input().strip().split(' '))

def li():
	return list(mi())

def dmain():
	sys.setrecursionlimit(1000000)
	threading.stack_size(1024000)
	thread = threading.Thread(target=main)
	thread.start()
import sys
input = sys.stdin.readline
scanner = lambda : int(input())
string = lambda : input().rstrip()
get_list = lambda : list(read())
read = lambda : map(int, input().split())
get_float = lambda : map(float, input().split())

def ceil(x):
	if x != int(x):
		x = int(x) + 1
	return x

def factorial(x, m):
	val = 1
	while x > 0:
		val = val * x % m
		x -= 1
	return val

def fact(x):
	val = 1
	while x > 0:
		val *= x
		x -= 1
	return val

def swaparr(arr, a, b):
	temp = arr[a]
	arr[a] = arr[b]
	arr[b] = temp

def gcd(a, b):
	if b == 0:
		return a
	return gcd(b, a % b)

def lcm(a, b):
	return a * b // math.gcd(a, b)

def is_integer(n):
	return math.ceil(n) == math.floor(n)

def nCr(n, k):
	if k > n:
		return 0
	if k > n - k:
		k = n - k
	res = 1
	for i in range(k):
		res = res * (n - i)
		res = res / (i + 1)
	return int(res)

def primefs(n):
	primes = {}
	while n % 2 == 0 and n > 0:
		primes[2] = primes.get(2, 0) + 1
		n = n // 2
	for i in range(3, int(n ** 0.5) + 2, 2):
		while n % i == 0 and n > 0:
			primes[i] = primes.get(i, 0) + 1
			n = n // i
	if n > 2:
		primes[n] = primes.get(n, 0) + 1
	return primes

def power(x, y, p):
	res = 1
	x = x % p
	if x == 0:
		return 0
	while y > 0:
		if y & 1 == 1:
			res = res * x % p
		y = y >> 1
		x = x * x % p
	return res

def swap(a, b):
	temp = a
	a = b
	b = temp
	return (a, b)

def find(x, link):
	p = x
	while p != link[p]:
		p = link[p]
	while x != p:
		nex = link[x]
		link[x] = p
		x = nex
	return p

def union(x, y, link, size):
	x = find(x, link)
	y = find(y, link)
	if size[x] < size[y]:
		(x, y) = swap(x, y)
	if x != y:
		size[x] += size[y]
		link[y] = x

def sieve(n):
	prime = [True for i in range(n + 1)]
	(prime[0], prime[1]) = (False, False)
	p = 2
	while p * p <= n:
		if prime[p] == True:
			for i in range(p * p, n + 1, p):
				prime[i] = False
		p += 1
	return prime

def phi(n):
	result = n
	p = 2
	while p * p <= n:
		if n % p == 0:
			while n % p == 0:
				n = n // p
			result = result * (1.0 - 1.0 / float(p))
		p = p + 1
	if n > 1:
		result = result * (1.0 - 1.0 / float(n))
	return int(result)

def is_prime(n):
	if n == 0:
		return False
	if n == 1:
		return True
	for i in range(2, int(n ** (1 / 2)) + 1):
		if not n % i:
			return False
	return True

def next_prime(n, primes):
	while primes[n] != True:
		n += 1
	return n
MAXN = int(100000.0 + 5)

def spf_sieve():
	spf[1] = 1
	for i in range(2, MAXN):
		spf[i] = i
	for i in range(4, MAXN, 2):
		spf[i] = 2
	for i in range(3, ceil(MAXN ** 0.5), 2):
		if spf[i] == i:
			for j in range(i * i, MAXN, i):
				if spf[j] == j:
					spf[j] = i
spf = [0 for i in range(MAXN)]

def factoriazation(x):
	res = []
	for i in range(2, int(x ** 0.5) + 1):
		while x % i == 0:
			res.append(i)
			x //= i
	if x != 1:
		res.append(x)
	return res

def factors(n):
	res = []
	for i in range(1, int(n ** 0.5) + 1):
		if n % i == 0:
			res.append(i)
			res.append(n // i)
	return list(set(res))

def int_array():
	return list(map(int, input().strip().split()))

def float_array():
	return list(map(float, input().strip().split()))

def str_array():
	return input().strip().split()

def binary_search(low, high, w, h, n):
	while low < high:
		mid = low + (high - low) // 2
		if check(mid, w, h, n):
			low = mid + 1
		else:
			high = mid
	return low

def check(beauty, s, n, count):
	pass

def sortSecond(val):
	return val[1]
MOD = int(1000000000.0) + 7
CMOD = 998244353
INF = float('inf')
NINF = -float('inf')
alphs = 'abcdefghijklmnopqrstuvwxyz'
from itertools import permutations
import math
import bisect as bis
import random
import sys
import collections as collect
import functools as fnt

def solve():
	(n, k) = read()
	a = get_list()
	a.sort()
	m = a[0]
	s = 0
	for x in a[1:]:
		s += (k - x) // m
	print(s)
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')

def print(*args, **kwargs):
	(sep, file) = (kwargs.pop('sep', ' '), kwargs.pop('file', sys.stdout))
	at_start = True
	for x in args:
		if not at_start:
			file.write(sep)
		file.write(str(x))
		at_start = False
	file.write(kwargs.pop('end', '\n'))
	if kwargs.pop('flush', False):
		file.flush()
if sys.version_info[0] < 3:
	(sys.stdin, sys.stdout) = (FastIO(sys.stdin), FastIO(sys.stdout))
else:
	(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
input = lambda : sys.stdin.readline().rstrip('\r\n')
t = scanner()
for i in range(t):
	solve()


from bisect import bisect_left, bisect_right
import os
import sys
from io import BytesIO, IOBase
from collections import Counter
from collections import deque
import math
import heapq
import re

def sin():
	return input()

def ain():
	return list(map(int, sin().split()))

def sain():
	return input().split()

def iin():
	return int(sin())
LOW = 'abcdefghijklmnopqrstuvwxyz'
UP = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'
MAX = float('inf')
MIN = float('-inf')
MOD = 1000000007

def sieve(n):
	prime = [True for i in range(n + 1)]
	p = 2
	while p * p <= n:
		if prime[p] == True:
			for i in range(p * p, n + 1, p):
				prime[i] = False
		p += 1
	s = set()
	for p in range(2, n + 1):
		if prime[p]:
			s.add(p)
	return s

def euc_d(p1, p2):
	return ((p1[0] - p2[0]) * (p1[0] - p2[0]) + (p1[1] - p2[1]) * (p1[1] - p2[1])) ** 0.5

def main():
	for _ in range(iin()):
		(n, k) = ain()
		l = ain()
		x = min(l)
		ans = 0
		c = 0
		for i in range(n):
			if l[i] != x:
				ans += (k - l[i]) // x
			else:
				c += 1
		p = (k - x) // x
		ans += (c - 1) * p
		print(ans)
BUFSIZE = 8192

class FastIO(IOBase):
	newlines = 0

	def __init__(self, file):
		self._fd = file.fileno()
		self.buffer = BytesIO()
		self.writable = 'x' in file.mode or 'r' not in file.mode
		self.write = self.buffer.write if self.writable else None

	def read(self):
		while True:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			if not b:
				break
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines = 0
		return self.buffer.read()

	def readline(self):
		while self.newlines == 0:
			b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
			self.newlines = b.count(b'\n') + (not b)
			ptr = self.buffer.tell()
			(self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr))
		self.newlines -= 1
		return self.buffer.readline()

	def flush(self):
		if self.writable:
			os.write(self._fd, self.buffer.getvalue())
			(self.buffer.truncate(0), self.buffer.seek(0))

class IOWrapper(IOBase):

	def __init__(self, file):
		self.buffer = FastIO(file)
		self.flush = self.buffer.flush
		self.writable = self.buffer.writable
		self.write = lambda s: self.buffer.write(s.encode('ascii'))
		self.read = lambda : self.buffer.read().decode('ascii')
		self.readline = lambda : self.buffer.readline().decode('ascii')
if os.getcwd() == 'D:\\code':
	sys.stdin = open('input.txt', 'r')
	sys.stdout = open('output.txt', 'w')
else:
	(sys.stdin, sys.stdout) = (IOWrapper(sys.stdin), IOWrapper(sys.stdout))
	input = lambda : sys.stdin.readline().rstrip('\r\n')
main()


import math
t = int(input())
for _ in range(t):
	(n, k) = list(map(int, input().split()))
	a = list(map(int, input().split()))
	a.sort()
	b = a[0]
	sumi = 0
	for i in range(1, n):
		c = k - a[i]
		sumi += c // b
	print(sumi)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	m = min(arr)
	res = 0
	for x in arr:
		res += (k - x) // m
	res -= (k - m) // m
	print(res)


t = int(input())
answers = []
for _ in range(t):
	x = 0
	nk = input().split()
	a = input().split()
	a_sorted = []
	for i in range(int(nk[0])):
		a_sorted.append(int(a[i]))
	a_sorted = sorted(a_sorted)
	for j in range(int(nk[0]) - 1):
		x += int((int(nk[1]) - a_sorted[-1 - j]) / a_sorted[0])
	answers.append(int(x))
for k in range(t):
	print(answers[k])


from sys import stdin, stdout
for _ in range(int(stdin.readline())):
	(n, k) = list(map(int, stdin.readline().split()))
	a = sorted(map(int, stdin.readline().split()))
	mn = a[0]
	ans = 0
	for i in range(1, n):
		ans += (k - a[i]) // mn
	print(ans)


l = []
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	min = a[0]
	flg = 0
	ind = 0
	for i in range(n):
		if min > a[i]:
			ind = i
			min = a[i]
	sum = 0
	count = 0
	for i in range(n):
		if k - a[i] >= min and i != ind:
			sum = sum + (k - a[i]) // min
		elif k - a[i] < 0:
			sum = 0
			flg = 1
			break
	l.append(sum)
for i in l:
	print(i)


for _ in range(int(input())):
	(n, k) = list(map(int, input().split()))
	a = list(map(int, input().split()))
	ma = min(a)
	ma_index = a.index(ma)
	print(sum([(k - item) // ma for (i, item) in enumerate(a) if i != ma_index]))


import itertools as it
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	arr = sorted(arr)
	c = 0
	for i in range(1, n):
		c = c + (k - arr[i]) // arr[0]
	print(c)


t = int(input())
for z in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	temp = min(a)
	ind = a.index(temp)
	count = 0
	for i in range(len(a)):
		if i != ind:
			te = k - a[i]
			count += te // temp
	print(count)


import sys
input = sys.stdin.readline
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	lis = sorted(map(int, input().split()))
	ans = 0
	for i in range(1, n):
		ans += (k - lis[i]) // lis[0]
	print(ans)


t = int(input())
while t:
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	l.sort()
	s = 0
	for i in range(1, len(l)):
		ans = k - l[i]
		s += ans // l[0]
	print(s)
	t = t - 1


from sys import stdin
from collections import defaultdict
input = stdin.readline
T = int(input())
for t in range(1, T + 1):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	res = 0
	for i in range(1, len(a)):
		res += (k - a[i]) // a[0]
	print(res)


import math
a = int(input())
for i in range(a):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	arr.sort()
	c = min(arr)
	ans = 0
	for i in range(1, len(arr)):
		if arr[i] < k:
			ans = ans + math.ceil((k - arr[i]) // c)
	print(ans)


from bisect import bisect_left
T = int(input())
for _ in range(T):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	tot = 0
	for i in range(1, n):
		tmp = (k - a[i]) // a[0]
		tot += tmp
	print(tot)


t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	b = sorted(a)
	count = 0
	target = b[0]
	for i in range(1, len(b)):
		count += (k - b[i]) // target
	print(count)


import sys
from math import ceil, factorial, gcd
from collections import Counter, deque, defaultdict
from bisect import bisect_left, bisect_right
from heapq import heappop, heappush, heapify
MOD = 10 ** 9 + 7
INF = float('inf')
rl = lambda : list(map(int, sys.stdin.readline().split()))
rs = lambda : sys.stdin.readline().strip()
for _ in range(int(input())):
	(n, k) = rl()
	A = rl()
	m = min(A)
	cnt = 0
	for a in A:
		cnt += max(0, (k - a) // m)
	print(cnt - (k - m) // m)


tc = int(input())
for _ in range(tc):
	(n, k) = map(int, input().split())
	ar = list(map(int, input().split()))
	ar.sort()
	j = len(ar) - 1
	res = 0
	while j > 0:
		if ar[j] + ar[0] > k:
			j -= 1
			continue
		ar[j] += ar[0]
		res += 1
	print(res)


t = int(input())
for r in range(t):
	(n, k) = list(map(int, input().split()))
	l = list(map(int, input().split()))
	c = 0
	z = 0
	p = min(l)
	for i in range(n):
		if l[i] == p:
			z = i
			break
	for i in range(n):
		if l[i] != k and i != z:
			c += (k - l[i]) // p
	print(c)


for _ in range(int(input())):
	(n, k) = list(map(int, input().split()))
	a = list(map(int, input().split()))
	bo = 1
	mn = min(a)
	if mn >= k:
		print(0)
		continue
	res = 0
	for i in range(n):
		if bo and a[i] == mn:
			bo = 0
			continue
		if a[i] < k and k - a[i] >= mn:
			res += (k - a[i]) // mn
	print(res)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	arr = sorted(list(map(int, input().split())), reverse=True)
	count = 0
	m = arr[-1]
	for i in range(n - 1):
		while arr[i] + m <= k:
			arr[i] += m
			count += 1
	print(count)


import sys
import math
import bisect
from sys import stdin, stdout
from math import gcd, floor, sqrt, log2, ceil, pi, sin, cos, acos, atan
from collections import defaultdict as dd
from bisect import bisect_left as bl, bisect_right as br
from bisect import insort
from collections import Counter
from collections import deque
from heapq import heappush, heappop, heapify
from itertools import permutations, combinations
mod = int(1000000000.0) + 7
ip = lambda : int(stdin.readline())
inp = lambda : map(int, stdin.readline().split())
ips = lambda : stdin.readline().rstrip()
out = lambda x: stdout.write(str(x) + '\n')
t = ip()
for _ in range(t):
	(n, k) = inp()
	arr = list(inp())
	arr.sort()
	ans = 0
	ele = arr[0]
	for i in range(1, n):
		ans += (k - arr[i]) // arr[0]
	out(ans)


def read_int():
	n = int(input())
	return n

def read_ints():
	ints = [int(x) for x in input().split(' ')]
	return ints

def solve(n, k, a):
	a.sort()
	mn = a[0]
	spells = 0
	for i in range(1, n):
		while a[i] + mn <= k:
			a[i] += mn
			spells += 1
	if a[0] + a[1] <= k:
		spells += 1
	return spells
t = read_int()
for case in range(t):
	(n, k) = read_ints()
	a = read_ints()
	sol = solve(n, k, a)
	print(sol)


import sys
from functools import lru_cache, cmp_to_key
from heapq import merge, heapify, heappop, heappush
from math import *
from collections import defaultdict as dd, deque, Counter as C
from itertools import combinations as comb, permutations as perm
from bisect import bisect_left as bl, bisect_right as br, bisect
from time import perf_counter
from fractions import Fraction
import copy
import time
starttime = time.time()
mod = int(pow(10, 9) + 7)
mod2 = 998244353

def data():
	return sys.stdin.readline().strip()

def out(*var, end='\n'):
	sys.stdout.write(' '.join(map(str, var)) + end)

def L():
	return list(sp())

def sl():
	return list(ssp())

def sp():
	return map(int, data().split())

def ssp():
	return map(str, data().split())

def l1d(n, val=0):
	return [val for i in range(n)]

def l2d(n, m, val=0):
	return [l1d(n, val) for j in range(m)]
try:
	sys.stdin = open('input.txt', 'r')
except:
	pass

def pmat(A):
	for ele in A:
		print(ele, end='\n')
for _ in range(L()[0]):
	(n, k) = L()
	A = L()
	A.sort()
	ans = 0
	for i in range(1, n):
		ans += max(k - A[i], 0) // A[0]
	print(ans)
endtime = time.time()


for _ in range(int(input())):
	(n, m) = map(int, input().split())
	l = list(map(int, input().split()))
	l.sort()
	c = 0
	for i in range(1, n):
		if l[i] < m:
			c += (m - l[i]) // l[0]
		else:
			break
	print(c)


from functools import reduce
import collections
import math
import sys

class Read:

	@staticmethod
	def string():
		return input()

	@staticmethod
	def int():
		return int(input())

	@staticmethod
	def list(delimiter=' '):
		return input().split(delimiter)

	@staticmethod
	def list_int(delimiter=' '):
		return list(map(int, input().split(delimiter)))

def main():
	t = Read.int()
	for _ in range(t):
		(n, k) = Read.list_int()
		a = sorted(Read.list_int())
		i = 1
		res = 0
		while i < n and a[i] < k:
			res += (k - a[i]) // a[0]
			i += 1
		print(res)
main()


import typing
import sys
import math
import collections
import bisect
import itertools
import fractions
import copy
import heapq
import decimal
import queue
INF = 10 ** 16
MOD = 998244353

def ni():
	return int(sys.stdin.readline())

def ns():
	return map(int, sys.stdin.readline().split())

def na():
	return list(map(int, sys.stdin.readline().split()))

def main():
	t = ni()
	for _ in range(t):
		(n, k) = ns()
		a = na()
		ans = 0
		flg = True
		base = min(a)
		for ai in a:
			if ai == base and flg:
				flg = False
				continue
			ans += max(0, k - ai) // base
		print(ans)
main()


a = int(input())
for j in range(0, a):
	(n, k) = map(int, input().split(' '))
	l1 = list(map(int, input().split(' ')))
	l1.sort()
	count = 0
	for i in range(0, len(l1)):
		difference = 0
		divide = 0
		if i == 0:
			continue
		else:
			difference = k - l1[i]
			divide = difference // l1[0]
			count += divide
	print(count)


try:
	for _ in range(int(input())):
		(n, k) = input().split(' ')
		n = int(n)
		k = int(k)
		arr = [int(i) for i in input().split(' ')]
		new = min(arr)
		arr.remove(new)
		count = 0
		for i in range(len(arr)):
			s = (k - arr[i]) // new
			count += s
		print(count)
except Exception:
	pass


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a = sorted(a)
	output = 0
	for x in a[1:]:
		output += (k - x) // a[0]
	print(output)


tests = int(input())
for t in range(tests):
	(n, k) = [int(i) for i in input().split(' ')]
	piles = [int(i) for i in input().split(' ')]
	min_pile_i = 0
	min_pile = piles[0]
	for i in range(1, len(piles)):
		if piles[i] < min_pile:
			min_pile = piles[i]
			min_pile_i = i
	tot = 0
	for i in range(len(piles)):
		if i != min_pile_i:
			tot += (k - piles[i]) // min_pile
	print(tot)


for _ in range(int(input())):
	ans = 0
	(n, k) = map(int, input().split())
	lst = sorted(list(map(int, input().split())))
	for i in range(1, n):
		ans += max((k - lst[i]) // min(lst), 0)
	print(ans)


for _ in range(int(input())):
	(n, k) = [int(i) for i in input().split()]
	candies = [int(i) for i in input().split()]
	smallest = min(candies)
	candies.remove(smallest)
	candies = [(k - i) // smallest for i in candies]
	print(sum(candies))


import sys
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	min1 = sys.maxsize
	min_idx = -1
	for i in range(n):
		if arr[i] < min1:
			min1 = arr[i]
			min_idx = i
	cnt = 0
	for i in range(n):
		if i != min_idx:
			cnt += (k - arr[i]) // min1
	print(cnt)


for test in range(int(input())):
	[n, k] = list(map(int, input().split(' ')))
	a = list(map(int, input().split(' ')))
	mi = min(a)
	tahy = [(k - ai) // mi for ai in a]
	res = sum(tahy) - (k - mi) // mi
	print(res)


for _ in range(int(input())):
	(n, k) = [int(i) for i in input().split()]
	w = [int(i) for i in input().split()]
	w.sort()
	a = w[0]
	count = 0
	for i in range(1, n):
		count += (k - w[i]) // a
	print(count)


import sys
input = sys.stdin.buffer.readline

def solution():
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	l.sort()
	ans = 0
	for i in range(1, n):
		if l[i] <= k:
			ans += (k - l[i]) // l[0]
	print(ans)
t = int(input())
for _ in range(t):
	solution()


cases = int(input())
for t in range(cases):
	(n, k) = list(map(int, input().split()))
	a = list(map(int, input().split()))
	v = min(a)
	a.remove(v)
	print(sum([(k - i) // v for i in a]))


testcases = int(input())
for _ in range(testcases):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	s = min(l)
	s_index = l.index(s)
	(moves, temp_moves) = (0, 0)
	for i in range(len(l)):
		if i == s_index:
			continue
		temp_moves = (k - l[i]) // s
		moves += temp_moves
		l[i] += temp_moves * s
	s = min(l[:s_index] + l[s_index + 1:])
	moves += (k - l[s_index]) // s
	print(moves)


for j in range(int(input())):
	(a, b) = map(int, input().split())
	c = list(map(int, input().split()))
	c1 = min(c)
	m = []
	v = 0
	for h in range(len(c)):
		if c[h] == c1:
			m = h
	for i in range(len(c)):
		if i != m:
			v = (b - c[i]) // c1 + v
	print(v)


import sys
import math
input = sys.stdin.readline

def inInt():
	return int(input())

def inStr():
	return input().strip('\n')

def inIList():
	return list(map(int, input().split()))

def inSList():
	return input().split()

def solve(n, l, k):
	m = min(l)
	s = 0
	for x in range(n):
		if k > l[x]:
			s = s + (k - l[x]) // m
	s = s - (k - m) // m
	print(s)
tasks = inInt()
for t in range(tasks):
	params = inIList()
	n = params[0]
	k = params[1]
	l = inIList()
	solve(n, l, k)


import math

def solve(n, k, res):
	ans = 0
	res.sort()
	for i in range(1, n):
		if res[i] >= k:
			continue
		else:
			ans = ans + (k - res[i]) // res[0]
	return ans
t = int(input())
while t:
	res = []
	(n, k) = map(int, input().split(' '))
	in_ = map(int, input().split(' '))
	for x in in_:
		res.append(int(x))
	print(solve(n, k, res))
	t -= 1


t = int(input())

def inp():
	return [int(i) for i in input().split()]
for i in range(t):
	(n, k) = inp()
	a = inp()
	m = min(a)
	ind = a.index(m)
	counts = 0
	for j in range(n):
		if a[j] <= k and j != ind:
			counts += (k - a[j]) // m
	print(counts)


t = int(input())
for i in range(t):
	(n, k) = input().split()
	(n, k) = (int(n), int(k))
	a = list(map(int, input().split()))
	m = a[0]
	mi = 0
	for i in range(n):
		if a[i] < m:
			mi = i
			m = a[i]
	s = 0
	for i in range(n):
		if i == mi:
			continue
		s += (k - a[i]) // m
	print(s)


m = int(input())
for i in range(m):
	(a, b) = input().split(' ')
	c = list(map(int, input().split(' ')))
	d = sorted(c)
	e = 0
	for k in range(1, int(a)):
		e += (int(b) - d[k]) // d[0]
	print(e)


t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	a = [int(x) for x in input().split()]
	s = min(a)
	a.remove(s)
	ans = 0
	for i in a:
		if k - i > 0:
			r = k - i
			ans = ans + r // s
	print(ans)


def inp():
	return int(input())

def inlt():
	return list(map(int, input().split()))

def insr():
	s = input()
	return list(s[:len(s) - 1])

def invr():
	return map(int, input().split())
t = inp()
for _ in range(t):
	(_, k) = inlt()
	a = inlt()
	add = min(range(len(a)), key=lambda i: a[i])
	res = 0
	for (i, num) in enumerate(a):
		if i == add:
			continue
		res += max(0, k - num) // a[add]
	print(res)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	minn = min(arr)
	counted = False
	ans = 0
	for a in arr:
		if a == minn and (not counted):
			counted = True
		else:
			ans += max(0, k - a) // minn
	print(ans)


t = int(input())
for _ in range(t):
	sum = 0
	(n, k) = list(map(int, input().split()))
	candies = sorted(list(map(int, input().split())))
	for i in range(1, n):
		sum += (k - candies[i]) // candies[0]
	print(sum)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	A = sorted(list(map(int, input().split())))
	res = 0
	minA = A[0]
	for a in A[1:]:
		res += max(k - a, 0) // minA
	print(res)


T = int(input())
KOLVO = []
for i in range(T):
	(n, k) = input().split()
	(n, k) = (int(n), int(k))
	MAS_N = [int(i) for i in input().split()]
	MAS_N = sorted(MAS_N)
	kolvo = 0
	z = 1
	while z < len(MAS_N):
		kolvo += (k - MAS_N[z]) // min(MAS_N)
		z += 1
	KOLVO.append(kolvo)
for i in range(len(KOLVO)):
	print(KOLVO[i])


for _ in range(int(input())):
	(n, k) = list(map(int, input().split()))
	arr = list(map(int, input().split()))
	arr.sort()
	(i, j) = (0, 1)
	c = 0
	while j < n:
		temp = arr[i] + arr[j]
		if temp <= k:
			t = k - arr[j]
			t = t // arr[i]
			c += t
		j += 1
	print(c)


t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	m = min(l)
	ind = l.index(m)
	count = 0
	for j in range(n):
		if j != ind:
			count += (k - l[j]) // m
	print(count)


t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	a = sorted(list(map(int, input().split())))
	ans = 0
	for j in range(1, n):
		ans += (k - a[j]) // a[0]
	print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	array = list(map(int, input().split()))
	array.sort()
	answer = 0
	for i in range(1, n):
		answer += (k - array[i]) // array[0]
	print(answer)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	li = list(map(int, input().split()))
	li.sort()
	sp = []
	for i in range(1, n):
		c = 0
		c = k - li[i]
		sp.append(c // li[0])
	su = sum(sp)
	print(su)


t = int(input())
for h in range(t):
	sh = list(map(int, input().split()))
	n = sh[0]
	k = sh[1]
	lis = list(map(int, input().split()))
	ans = 0
	x = min(lis)
	lis.remove(x)
	for i in range(n - 1):
		s = (k - lis[i]) // x
		if s > 0:
			ans += s
	print(ans)


for o in range(int(input())):
	(n, k) = map(int, input().split())
	s = list(map(int, input().split()))
	a = min(s)
	p = 0
	c = 0
	if max(s) > k:
		p = 0
	else:
		for i in range(n):
			if c == 1 or s[i] != a:
				p = p + (k - s[i]) // a
			if s[i] == a:
				c = 1
	print(p)


from heapq import *
input = __import__('sys').stdin.readline
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	s = sorted(map(int, input().split()))
	ans = 0
	for i in s[1:]:
		ans += (k - i) // s[0]
	print(ans)


for T in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	m = a[0]
	if a[-1] > k:
		print(0)
	else:
		c = 0
		for val in a[1:n]:
			c += (k - val) // a[0]
		print(c)


import heapq
t = int(input())
while t != 0:
	(n, k) = map(int, input().split())
	list1 = list(map(int, input().split()))
	list1.sort()
	s = 0
	for i in range(1, len(list1)):
		if k - list1[i] > 0:
			s += (k - list1[i]) // list1[0]
	print(s)
	t -= 1


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	mi = min(a)
	s = 0
	for i in a:
		s += (k - i) // mi
	s -= (k - mi) // mi
	print(s)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	nums = list(map(int, input().split()))
	min1 = min(nums)
	count = 0
	ind = nums.index(min1)
	for i in range(n):
		if i == ind:
			continue
		if nums[i] == k:
			continue
		else:
			count = count + (k - nums[i]) // min1
	print(count)


T = int(input())
for i in range(T):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	arr.sort()
	ans = 0
	for j in range(1, n):
		if k >= arr[j] + arr[0]:
			ans += (k - arr[j]) // arr[0]
	print(ans)


import math
from collections import deque
from collections import defaultdict
t = int(input())
while t > 0:
	t -= 1
	(n, k) = map(int, input().strip().split(' '))
	arr = list(map(int, input().strip().split(' ')))
	ans = 0
	arr.sort()
	ad = arr[0]
	for i in range(1, n):
		dff = k - arr[i]
		if arr[i] + ad > k:
			break
		ans += dff // ad
	print(ans)


T = int(input())

def add(who, whom):
	whom += who

def how_much(num, k, add):
	return (k - num) // add
for _ in range(T):
	line = input()
	line = [int(x) for x in line.split()]
	n = line[0]
	k = line[1]
	a = []
	line = input()
	line = [int(x) for x in line.split()]
	for i in line:
		a.append(i)
	a = sorted(a)
	counter = 0
	for i in range(1, len(a))[::-1]:
		how_much_value = how_much(a[i], k, a[0])
		a[i] += a[0] * how_much_value
		counter += how_much_value
	least_last = min(a[1:])
	how_much_value = how_much(a[0], k, least_last)
	a[0] += least_last * how_much_value
	counter += how_much_value
	print(counter)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	ans = 0
	for i in range(n - 1, -1, -1):
		try:
			cnt = max(0, k - a[i]) // min(a[:i])
			ans += cnt
			a[i] += min(a[:i]) * cnt
		except:
			ans += 0
	print(ans)


for i in range(int(input())):
	(n, k) = list(map(int, input().split()))
	a = list(map(int, input().split()))
	ans = 0
	x = min(a)
	a.remove(min(a))
	for i in range(len(a)):
		ans += (k - a[i]) // x
	print(ans)


t = int(input())
i = 0
while i < t:
	(n, k) = input().split()
	n = int(n)
	k = int(k)
	a = list(map(int, input().split()))
	v = min(a)
	a.remove(v)
	j = 0
	s = 0
	while j < n - 1:
		if k > a[j]:
			s += (k - a[j]) // v
		j += 1
	print(abs(s))
	i += 1


import sys
t = int(input())
for _ in range(t):
	(n, k) = [int(c) for c in input().split()]
	a = [int(c) for c in input().split()]
	m = min(a)
	mi = a.index(m)
	res = 0
	for i in range(n):
		if i == mi:
			continue
		diff = k - a[i]
		res += diff // m
	print(res)


t = int(input())
for i in range(t):
	(a, b) = map(int, input().split())
	lst = list(map(int, input().split()))
	lst.sort()
	c = lst[0]
	count = 0
	for i in range(1, len(lst)):
		if lst[i] >= b:
			continue
		else:
			cc = b - lst[i]
			count += cc // c
	print(count)


import math
t = int(input())
val = []
arr = []
for i in range(t):
	val.append(list(map(int, input().split(' '))))
	arr.append(list(map(int, input().split(' '))))
for i in range(len(arr)):
	new_arr = sorted(arr[i])
	min_val = new_arr[0]
	k = val[i][1]
	total_steps = 0
	for j in range(1, len(new_arr)):
		total_steps += int((k - new_arr[j]) / min_val)
	print(total_steps)


try:
	for t in range(int(input())):
		(n, k) = map(int, input().split())
		l = [int(x) for x in input().split()][:n]
		l = sorted(l)
		a = l[0]
		count = 0
		temp = 0
		for i in range(1, len(l)):
			temp = k
			temp = temp - l[i]
			count = count + temp // a
		print(count)
except:
	pass


for _ in range(int(input())):
	(n, k) = [int(i) for i in input().split()]
	a = [int(i) for i in input().split()]
	m = min(a)
	ans = 0
	for i in a:
		ans += (k - i) // m
	ans -= (k - m) // m
	print(ans)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	m = l[0]
	index = 0
	for i in range(1, n):
		if l[i] < m:
			m = l[i]
			index = i
	c = 0
	for i in range(n):
		if i != index and l[i] <= k:
			c += (k - l[i]) // m
	print(c)


import math

def get_int():
	return int(input())

def get_ints():
	return [int(i) for i in input().split()]
for t in range(0, get_int()):
	(n, k) = get_ints()
	candles = get_ints()
	candles.sort()
	pastes = 0
	lowest = candles[0]
	for i in range(1, n):
		dif = k - candles[i]
		if dif > 0:
			pastes += dif // lowest
	print(pastes)


def main():
	for _ in range(int(input())):
		(n, k) = map(int, input().split())
		a = list(map(int, input().split()))
		ans = 0
		for i in range(n):
			idx = -1
			res = 100000
			for j in range(n):
				if a[j] < res:
					idx = j
					res = a[j]
			for j in range(n):
				if j == idx:
					continue
				x = (k - a[j]) // res
				ans += x
				a[j] += x * res
		print(ans)
main()


def solve(arr, k):
	n = len(arr)
	arr.sort(reverse=True)
	MIN = arr.pop()
	count = 0
	for ele in arr:
		count += (k - ele) // MIN
	return count
t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	ans = solve(arr, k)
	print(ans)


for _ in range(int(input())):
	(n, k) = [int(i) for i in input().split()]
	l = [int(i) for i in input().split()]
	l.sort()
	mn = l[0]
	ans = 0
	for i in range(n - 1, 0, -1):
		if l[i] < k:
			d = k - l[i]
			ans += int(d / mn)
	print(ans)


def solve(arr, k, n):
	arr.sort()
	c = 0
	minval = arr[0]
	for i in range(1, n):
		if arr[i] + minval <= k:
			diff = k - arr[i]
			c += diff // minval
	return c
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	print(solve(l, k, n))


t = int(input())
for case in range(t):
	(n, k) = [int(s) for s in input().split(' ')]
	a = [int(s) for s in input().split(' ')]
	m = min(a)
	a.remove(m)
	x = sum([max(0, (k - y) // m) for y in a])
	print(x)


t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	b = list(map(int, input().split()))
	a = min(b)
	s = 0
	f = False
	for q in b:
		if q != a:
			s += (k - q) // a
		elif not f:
			f = True
		else:
			s += (k - q) // a
	print(s)


MAXN = 1005
T = int(input())
for _ in range(T):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	for (i, ai) in enumerate(a):
		if a[0] > ai:
			(a[0], a[i]) = (a[i], a[0])
	ans = 0
	for ai in a[1:]:
		ans += (k - ai) // a[0]
	print(ans)


def solve(n, k, arr):
	mini = min(arr)
	oper = 0
	for i in arr:
		oper += (k - i) // mini
	return oper - (k - mini) // mini
for _ in [0] * int(input()):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	print(solve(n, k, arr))


from sys import stdin, stdout
input = stdin.buffer.readline
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	(*a,) = map(int, input().split())
	a.sort()
	ans = 0
	mn = 100000000
	for i in range(1, n):
		ans += (k - a[i]) // a[0]
		mn = min(mn, a[i] + (k - a[i]) // a[0] * a[0])
	ans += (k - a[0]) // mn
	print(ans)


MOD = 1000000007
from collections import defaultdict as dd, Counter, deque

def si():
	return input()

def ii():
	return int(input())

def li():
	return list(map(int, input().split()))

def mi():
	return map(int, input().split())

def out(v):
	print(v)

def spout():
	print(v, end=' ')

def d2b(n):
	return bin(n).replace('0b', '')

def twod(n, m, num):
	return [[num for x in range(m)] for y in range(n)]

def vow():
	return ['a', 'e', 'i', 'o', 'u']

def let():
	return [chr(i) for i in range(97, 123)]

def gcd(x, y):
	while y:
		(x, y) = (y, x % y)
	return x

def ispow2(x):
	return x and (not x & x - 1)

def prime_factors(n):
	i = 2
	factors = []
	while i * i <= n:
		if n % i:
			i += 1
		else:
			n //= i
			factors.append(i)
	if n > 1:
		factors.append(n)
	return list(factors)
t = ii()
while t:
	t -= 1
	(n, k) = mi()
	a = li()
	a.sort()
	m = a[0]
	s = 0
	for i in range(1, n):
		if a[i] < k:
			s += (k - a[i]) // m
	print(s)


import math
t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	ans = 0
	for i in range(1, n):
		ans += max((k - a[i]) // a[0], 0)
	print(ans)


def readis():
	return map(int, input().strip().split())
T = int(input())
ans = []
while T:
	T -= 1
	(n, k) = readis()
	xs = list(readis())
	x_min = min(xs)
	xs.remove(x_min)
	count = 0
	for x in xs:
		count += (k - x) // x_min
	ans.append(count)
for a in ans:
	print(a)


m = int(input())
l = []
for _ in range(m):
	(t, an) = map(int, input().split())
	a = list(map(int, input().split()))
	d = min(a)
	a.remove(d)
	s = 0
	for i in a:
		s += (an - i) // d
	l.append(s)
for i in l:
	print(i)


import sys
import os.path
if os.path.exists('input_file.txt'):
	sys.stdin = open('input_file.txt', 'r')
	sys.stdout = open('output_file.txt', 'w')
mod = 1000000007

def factorial(a):
	ans = 1
	for i in range(1, a + 1):
		ans = ans * i % mod
	return ans
import math
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	ans = 0
	a.sort()
	aa = a[0]
	for i in a[1:]:
		if i >= k:
			pass
		else:
			ans += (k - i) // aa
	print(ans)


for t in range(int(input())):
	nk = list(map(int, input().split()))
	a = list(map(int, input().split()))
	a.sort()
	res = 0
	for i in range(nk[0] - 1, 0, -1):
		res += (nk[1] - a[i]) // a[0]
	print(res)


t = int(input())
while t > 0:
	t -= 1
	(n, k) = list(map(int, input().split()))
	a = list(map(int, input().split()))
	a.sort()
	val = a[0]
	ans = 0
	for i in range(1, n):
		if a[i] < k:
			ans += (k - a[i]) // val
	print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	r = 0
	for i in range(1, n):
		d = k - a[i]
		if d <= 0:
			continue
		r += d // a[0]
	print(r)


def solve(nums, k):
	ans = 0
	min_element = nums.index(min(nums))
	for i in range(len(nums)):
		if i != min_element:
			while nums[i] + nums[min_element] <= k:
				nums[i] += nums[min_element]
				ans += 1
	return ans
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	nums = list(map(int, input().split()))
	print(solve(nums, k))


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	l1 = list(map(int, input().split()))
	l1.sort(reverse=True)
	a = l1[n - 1]
	ans = 0
	for i in range(n - 1):
		if l1[i] > k:
			continue
		else:
			x = k - l1[i]
			ans += x // a
	print(ans)


import math, sys
from sys import stdin, stdout
from collections import Counter, defaultdict, deque
input = stdin.readline
I = lambda : int(input())
li = lambda : list(map(int, input().split()))

def solve():
	(n, k) = li()
	a = li()
	ans = 0
	a.sort()
	for i in range(1, n):
		ans += (k - a[i]) // a[0]
	print(ans)
for _ in range(I()):
	solve()


from math import *
from cmath import *
from itertools import *
from decimal import *
from fractions import *
from sys import *
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = [int(x) for x in input().split()]
	(x, ans) = (min(a), 0)
	for y in a:
		ans += (k - y) // x
	print(ans - (k - x) // x)


t = int(input())
while t:
	t -= 1
	(n, k) = input().split()
	(n, k) = (int(n), int(k))
	arr = [int(i) for i in input().split()]
	mini = 10000000000.0
	minind = 0
	for i in range(n):
		if arr[i] < mini:
			mini = arr[i]
			minind = i
	count = 0
	for i in range(n):
		if i != minind:
			count += (k - arr[i]) // mini
	print(count)


from collections import Counter
import string
import math
import sys
sys.setrecursionlimit(10 ** 6)

def array_int():
	return [int(i) for i in sys.stdin.readline().split()]

def vary(number_of_variables):
	if number_of_variables == 1:
		return int(sys.stdin.readline())
	if number_of_variables >= 2:
		return map(int, sys.stdin.readline().split())

def makedict(var):
	return dict(Counter(var))
for _ in range(vary(1)):
	(n, k) = vary(2)
	num = array_int()
	num.sort()
	i = 0
	count = 0
	j = 1
	for i in range(1, n):
		count += (k - num[i]) // num[0]
	print(count)


T = int(input())
while T > 0:
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	arr.sort()
	res = 0
	mi = float('inf')
	for i in range(1, n):
		res += (k - arr[i]) // arr[0]
		tmp = (k - arr[i]) % arr[0]
		mi = min(mi, k - tmp)
	res += (k - arr[0]) // mi
	print(res)
	T -= 1


n = int(input())
for i in range(n):
	k = list(map(int, input().strip().split()))
	a = list(map(int, input().strip().split()))
	a = sorted(a)
	c = 0
	for i in range(1, len(a)):
		p = (k[1] - a[i]) // a[0]
		c += p
	print(c)


t = int(input())
for x in range(t):
	(n, k) = input().split()
	k = int(k)
	a = input().split()
	a = [int(x) for x in a]
	a.sort()
	count = 0
	for y in range(1, len(a)):
		count += (k - a[y]) // a[0]
	print(count)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	A = list(map(int, input().split()))
	A.sort()
	ans = 0
	for i in range(1, n):
		if A[i] > k:
			ans = 0
			break
		rem = k - A[i]
		ans += rem // A[0]
	print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	A = list(map(int, input().split()))
	m = min(A)
	print(sum([(k - a) // m for a in A]) - (k - m) // m)


T = int(input())
for t in range(T):
	(N, K) = [int(_) for _ in input().split()]
	A = [int(_) for _ in input().split()]
	answer = 0
	m = min(A)
	im = A.index(m)
	for i in range(N):
		if i == im:
			continue
		answer += (K - A[i]) // m
	print(answer)


T = int(input())
for i in range(T):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	count = 0
	l.sort()
	m = l[0]
	for j in range(1, n):
		count += (k - l[j]) // m
	print(count)


for _ in range(int(input())):
	(x, y) = map(int, input().split())
	myList = list(map(int, input().split()))
	myList.sort()
	out = 0
	for i in range(1, len(myList)):
		v = (y - myList[i]) // myList[0]
		if v < 0:
			out = 0
			break
		out += (y - myList[i]) // myList[0]
	print(out)


import sys
import math
from collections import defaultdict, Counter
input = sys.stdin.readline

def print(x):
	sys.stdout.write(str(x) + '\n')
t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	mi = min(a)
	flag = 0
	ans = 0
	for j in a:
		if j == mi and flag == 0:
			flag = 1
			continue
		ans += (k - j) // mi
	print(ans)


import math
for _ in range(int(input())):
	sum = 0
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	z = a[0]
	a.remove(z)
	for i in a:
		s = k - i
		g = s // z
		sum += g
	print(sum)


import sys
import math
from collections import Counter
from collections import OrderedDict

def inputt():
	return sys.stdin.readline().strip()

def printt(n):
	sys.stdout.write(str(n) + '\n')

def listt():
	return [int(i) for i in inputt().split()]

def gcd(a, b):
	return math.gcd(a, b)

def lcm(a, b):
	return a * b / gcd(a, b)

def dfs(src, visit):
	visit[src] = 1
	for nbr in dic[src]:
		if visit[nbr] == 0:
			dfs(nbr, visit)
t = int(inputt())
for _ in range(t):
	(n, k) = map(int, inputt().split())
	l = listt()
	dic = Counter(l)
	mi = min(dic.keys())
	ans = 0
	for (key, value) in dic.items():
		if key != mi:
			ans += value * (abs(k - key) // mi)
		if key == mi and value > 1:
			ans += (value - 1) * (abs(k - key) // mi)
	printt(ans)


import sys
import math as m

def main():
	pass

def binary(n):
	return bin(n).replace('0b', '')

def decimal(s):
	return int(s, 2)

def pow2(n):
	p = 0
	while n > 1:
		n //= 2
		p += 1
	return p

def isPrime(n):
	if n == 1:
		return False
	else:
		root = int(n ** 0.5)
		root += 1
		for i in range(2, root):
			if n % i == 0:
				return False
		return True

def lts(l):
	s = ''.join(map(str, l))
	return s

def stl(s):
	l = list(s)
	return l
mod = int(1000000000.0) + 7

def sinp():
	return sys.stdin.readline().strip()

def iinp():
	return int(input())

def ninp():
	return map(int, sys.stdin.readline().strip().split())

def linp():
	return list(map(int, sys.stdin.readline().strip().split()))

def p(a):
	print(a)

def p2(a, b):
	print(a, b)
for _ in range(iinp()):
	(n, k) = ninp()
	a = linp()
	a.sort()
	m = min(a)
	f = 0
	cnt = 0
	for i in a:
		if f == 0:
			f += 1
		else:
			x = (k - i) // m
			cnt = cnt + x
	print(cnt)


def solve(lst, k):
	minVal = max(lst)
	ind = lst[0]
	ans = 0
	for i in range(len(lst)):
		if lst[i] < minVal:
			minVal = lst[i]
			ind = i
	for i in range(len(lst)):
		if ind == i:
			continue
		ans += (k - lst[i]) // minVal
	return ans
m = int(input())
for i in range(m):
	(k, m) = map(int, input().split(' '))
	lst = list(map(int, input().split(' ')))
	print(solve(lst, m))


for qq in range(int(input())):
	(n, k) = map(int, input().split())
	a = sorted(map(int, input().split()))
	ans = 0
	for i in range(1, n):
		ans += (k - a[i]) // a[0]
	print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	l.sort()
	count = 0
	for i in range(1, n):
		if l[i] < k and l[i] + l[0] <= k:
			count += (k - l[i]) // l[0]
	print(count)


import math
from collections import defaultdict
import functools as f
from itertools import permutations as p
t = 1
t = int(input())
for _ in range(t):
	(n, k) = list(map(int, input().split()))
	l = list(map(int, input().split()))
	l.sort()
	mi = l[0]
	an = 0
	for i in range(1, n):
		if l[i] <= k:
			while True:
				if l[i] > k:
					break
				l[i] += mi
				if l[i] > k:
					break
				an += 1
	print(an)


import math
ts = int(input())
for t in range(ts):
	(n, k) = input().split()
	(n, k) = (int(n), int(k))
	arr = []
	arr = input().split()
	for i in range(n):
		arr[i] = int(arr[i])
	arr.sort()
	ans = 0
	for i in range(n):
		if i == 0:
			continue
		ans += int((k - arr[i]) / arr[0])
	print(math.floor(ans))


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	piles = tuple(map(int, input().split()))
	min_pile = piles[0]
	min_index = 0
	for i in range(1, n):
		if piles[i] < min_pile:
			(min_index, min_pile) = (i, piles[i])
	ans = 0
	if min_pile > k:
		print(0)
	else:
		for i in range(n):
			if i == min_index:
				pass
			elif min_pile <= piles[i] <= k:
				ans += (k - piles[i]) // min_pile
		print(ans)


def solve():
	(n, k) = map(int, input().strip().split())
	a = list(map(int, input().strip().split()))
	m = min(a)
	ans = -(max(k - m, 0) // m)
	for i in range(n):
		diff = max(k - a[i], 0)
		ans += diff // m
	print(ans)
t = int(input().strip())
for _ in range(t):
	solve()


from math import floor
outs = []
t = int(input())
for temp in range(t):
	out = 0
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	min_id = a.index(min(a))
	for i in range(n):
		if not i == min_id:
			out += int(floor((k - a[i]) / a[min_id]))
	outs.append(out)
for i in outs:
	print(i)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	minn = min(a)
	a.sort()
	if max(a) > k:
		print(0)
	else:
		flag = 1
		cnt = 0
		for i in range(1, n):
			cnt = cnt + (k - a[i]) // minn
		print(cnt)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	ar = list(map(int, input().split()))
	ar.sort()
	low = ar[0]
	count = 0
	for i in range(1, len(ar)):
		if ar[i] + low <= k:
			count += int((k - ar[i]) / low)
	print(count)


import os
from sys import stdin, stdout

def solve(tc):
	(n, k) = map(int, stdin.readline().split())
	seq = list(map(int, stdin.readline().split()))
	cnt = 0
	seq = sorted(seq)
	for i in range(1, n):
		if seq[i] + seq[0] <= k:
			cnt += (k - seq[i]) // seq[0]
	print(cnt)
tcs = 1
tcs = int(stdin.readline().strip())
tc = 1
while tc <= tcs:
	solve(tc)
	tc += 1


t = int(input())
for i in range(t):
	(n, k) = list(map(int, input().split()))
	arr = list(map(int, input().split()))
	arr.sort()
	small = arr[0]
	ans = 0
	for j in range(1, n):
		ans += (k - arr[j]) // small
	print(ans)


for x in range(int(input())):
	k = list(map(int, input().split()))
	n = list(map(int, input().split()))
	n.sort()
	counter = 0
	for i in range(1, len(n)):
		counter += (k[1] - n[i]) // n[0]
	print(counter)


t = int(input())
while t:
	(n, k) = [int(x) for x in input().split()]
	a = [int(x) for x in input().split()]
	m = min(a)
	a.remove(m)
	print(sum([(k - x) // m for x in a]))
	t -= 1


t = int(input())
while t > 0:
	t -= 1
	(n, k) = (int(i) for i in input().split())
	a = [int(i) for i in input().split()]
	least = min(a)
	ans = 0
	for i in a:
		ans += (k - i) // least
	ans -= (k - least) // least
	print(ans)


T = int(input())
for t in range(T):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	i = min(a)
	count = 0
	for j in range(n):
		count += (k - a[j]) // i
	count -= (k - i) // i
	print(count)


m = int(input())
for i in range(m):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	counter = 0
	min1 = 100000000000
	for i in range(len(a) - 1, 0, -1):
		counter += (k - a[i]) // a[0]
		a[i] = a[i] + (k - a[i]) // a[0] * a[0]
		min1 = min(min1, a[i])
	if a[0] + min1 < k:
		counter += 1
	print(counter)


t = int(input())
for i in range(t):
	(n, k) = map(int, input().split())
	s = [int(i) for i in input().split()]
	s.sort()
	x = s[0]
	y = [(k - s[i]) // x if x > 1 else k - s[i] for i in range(1, n)]
	print(sum(y))


t = int(input())
for i in range(t):
	res = 0
	(n, k) = map(int, input().split())
	lst = list(map(int, input().split(' ')[:n]))
	lst.sort()
	for j in range(1, n):
		if lst[j] > k:
			continue
		else:
			res = res + (k - lst[j]) // lst[0]
	print(res)


T = int(input())
while T:
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	m = min(arr)
	arr.remove(m)
	counts = 0
	for i in arr:
		if i < k:
			counts += (k - i) // m
	print(counts)
	T -= 1


T = int(input())
for _ in range(T):
	(n, k) = [int(i) for i in input().split()]
	arr = [int(i) for i in input().split()]
	arr.sort()
	adder = arr[0]
	count = 0
	for numbers in arr[1:]:
		if numbers >= k:
			break
		count += (k - numbers) // adder
	print(count)


t = int(input())
for i in range(t):
	(n, k) = [int(h) for h in input().split()]
	stroka = sorted([int(j) for j in input().split()])
	minn = stroka[0]
	count = 0
	for j in range(1, n):
		count += (k - stroka[j]) // minn
	print(count)


def solve():
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	l.sort()
	(a, b) = (l[0], l[1])
	ans = 0
	for i in range(1, n):
		ans += (k - l[i]) // a
	print(ans)
t = int(input())
for _ in range(t):
	solve()


try:
	test = int(input())
	for _ in range(test):
		(n, k) = input().split()
		n = int(n)
		k = int(k)
		arr = list(map(int, input().split()))
		min_ele = min(arr)
		arr.remove(min_ele)
		for item in arr:
			if item > k:
				arr.remove(item)
		count = 0
		for item in arr:
			item = k - item
			count += item // min_ele
		print(count)
except:
	pass


t = int(input())
for _ in range(t):
	(n, k) = tuple(map(int, input().split()))
	nums = list(map(int, input().split()))
	minim = min(nums)
	ans = 0
	for i in nums:
		ans += (k - i) // minim
	ans -= (k - minim) // minim
	print(ans)


T = int(input())
for I in range(0, T):
	X = input().split(' ')
	Y = sorted(list(map(int, input().split(' '))))
	Z = 0
	for I in range(1, len(Y)):
		if int(X[1]) > Y[I]:
			Z += (int(X[1]) - Y[I]) // Y[0]
	print(int(Z))


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	m = 0
	arr.sort()
	while len(arr) > 1:
		arr[-1] += arr[0]
		if arr[-1] <= k:
			m += 1
		if arr[-1] >= k:
			arr.remove(arr[-1])
	print(m)


for i in range(int(input())):
	(a, b) = map(int, input().split())
	c = sorted(map(int, input().split()))
	d = c[0]
	e = 0
	for i in range(1, len(c)):
		e += (b - c[i]) // d
	print(e)


import sys
import os
import math
import copy
from math import gcd
from bisect import bisect
from io import BytesIO, IOBase
from math import sqrt, floor, factorial, gcd, log, ceil
from collections import deque, Counter, defaultdict
from itertools import permutations, combinations
from itertools import accumulate

def Int():
	return int(sys.stdin.readline())

def Mint():
	return map(int, sys.stdin.readline().split())

def Lstr():
	return list(sys.stdin.readline().strip())

def Str():
	return sys.stdin.readline().strip()

def Mstr():
	return map(str, sys.stdin.readline().strip().split())

def List():
	return list(map(int, sys.stdin.readline().split()))

def Hash():
	return dict()

def Mod():
	return 1000000007

def Ncr(n, r, p):
	return fact[n] * (ifact[r] * ifact[n - r] % p) % p

def Most_frequent(list):
	return max(set(list), key=list.count)

def Mat2x2(n):
	return [List() for _ in range(n)]

def Lcm(x, y):
	return x * y // gcd(x, y)

def dtob(n):
	return bin(n).replace('0b', '')

def btod(n):
	return int(n, 2)

def common(l1, l2):
	return set(l1).intersection(l2)

def solution():
	for _ in range(Int()):
		(n, k) = Mint()
		a = List()
		a.sort()
		mi = a[0]
		ans = 0
		for i in range(1, n):
			ans += (k - a[i]) // mi
		print(ans)
solution()


n = int(input())
for i in range(n):
	(n, k) = [int(x) for x in input().split()]
	l = [int(x) for x in input().split()]
	m = 100000
	mi = 0
	for j in range(n):
		if l[j] < m:
			m = l[j]
			mi = j
	c = 0
	for x in range(n):
		if x != mi:
			c += (k - l[x]) // m
	print(c)


def main():
	for _ in range(int(input())):
		(n, k) = map(int, input().split())
		candies = list(map(int, input().split()))
		candies.sort()
		i = candies[0]
		count = 0
		for j in range(1, n):
			if k >= candies[j]:
				count += (k - candies[j]) // i
		print(count)
main()


import bisect
import collections
import copy
import fractions
import functools
import heapq
import math
import random
import sys

def _p(str):
	sys.stdout.write(str + '\n')

def _i():
	return sys.stdin.readline()
T = int(_i())
for t in range(T):
	(N, K) = tuple(map(int, _i().split()))
	A = list(map(int, _i().split()))
	min_ = min(A)
	for i in range(N):
		if A[i] == min_:
			min_ind = i
			break
	casts = 0
	for i in range(N):
		if i != min_ind:
			casts += math.floor((K - A[i]) / min_)
	_p(str(casts))
sys.stdout.flush()


import sys
import itertools
import math
input = sys.stdin.readline
I = lambda : list(map(int, input().split()))
(n,) = I()
while n:
	n -= 1
	(m, k) = I()
	arr = sorted(I())
	ele = arr[0]
	sumi = 0
	for i in range(1, m):
		sumi += math.floor((k - arr[i]) / ele)
	print(sumi)


t = int(input())
for i in range(t):
	temp = [int(x) for x in input().split()]
	n = temp[0]
	k = temp[1]
	a = [int(x) for x in input().split()]
	m = min(a)
	x = a.index(m)
	result = 0
	for j in range(n):
		if j == x:
			continue
		result += (k - a[j]) // m
	print(result)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	l = [int(x) for x in input().split()]
	l.sort()
	s = 0
	for i in range(1, n):
		s += (k - l[i]) // l[0]
	print(s)


t = int(input())
for _ in range(t):
	(_, k) = [int(i) for i in input().split()]
	A = [int(i) for i in input().split()]
	minimum = min(A)
	minimum_index = A.index(minimum)
	ans = 0
	for i in range(len(A)):
		if i != minimum_index:
			ans += int((k - A[i]) / minimum)
	print(ans)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	ai = list(map(int, input().split()))
	ai.sort()
	summ = 0
	for i in range(1, n):
		p = ai[i]
		ai[i] = (k - ai[i]) // ai[0]
		if ai[i] < 0:
			print(0)
			break
		else:
			summ += ai[i]
			ai[i] = p + ai[0] * ai[i]
	else:
		mini = 1000000000
		for i in range(1, n):
			mini = min(ai[i], mini)
		summ += (k - ai[0]) // mini
		print(summ)


number_of_pairs = int(input())
answers = []
for i in range(number_of_pairs):
	input_data = input().split()
	number_of_groups = int(input_data[0])
	max_cookie = int(input_data[1])
	array = []
	array = input().split()
	for i in range(number_of_groups):
		array[i] = int(array[i])
	answer = 0
	active = True
	array.sort()
	for i in range(1, number_of_groups):
		while array[i] <= max_cookie:
			array[i] += array[0]
			if array[i] <= max_cookie:
				answer += 1
	answers.append(answer)
for i in answers:
	print(i)


tc = int(input())
for _ in range(tc):
	[n, k] = list(map(int, input().split()))
	arr = list(map(int, input().split()))
	narr = sorted(arr)
	i = 1
	top = 0
	while i < n:
		if narr[i] < k:
			top += (k - narr[i]) // narr[0]
		else:
			break
		i += 1
	print(top)


for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = [int(x) for x in input().split()]
	mine = min(a)
	idx = a.index(mine)
	ans = 0
	for z in range(n):
		if z != idx:
			ans += (k - a[z]) // mine
	print(ans)


for i in range(int(input())):
	(n, k) = map(int, input().split())
	a = sorted([int(num) for num in input().split()])
	(p, ans) = (min(a), 0)
	if p < k:
		for i in a[1:]:
			ans += (k - i) // p
	print(ans)


import bisect
import array
import functools
import math
T = int(input())
for Tid in range(T):
	(n, k) = map(int, input().split())
	a = array.array('i', map(int, input().split()))
	a = sorted(a)
	ans = 0
	for i in range(1, n):
		ans = ans + (k - a[i]) // a[0]
	print(ans)


t = int(input())
for _ in range(t):
	(n, k) = map(int, input().split())
	l = [int(x) for x in input().split()]
	l.sort()
	i = 0
	j = n - 1
	su = 0
	while j > 0:
		su += (k - l[j]) // l[i]
		j -= 1
	print(su)


import sys
input = sys.stdin.readline

def main():
	(n, k) = map(int, input().split())
	alst = list(map(int, input().split()))
	alst.sort()
	min_ = alst[0]
	ans = 0
	for a in alst[1:]:
		num = k - a
		ans += num // min_
	print(ans)
for _ in range(int(input())):
	main()


t = int(input())
for i in range(t):
	(n, k) = [int(i) for i in input().split()]
	arr = []
	ans = 0
	for j in input().split():
		arr.append(int(j))
	m = min(arr)
	del arr[arr.index(m)]
	for i in arr:
		ans += (k - i) // m
	print(ans)


from collections import *
from functools import *
import math
import sys
inp = sys.stdin.readline
out = sys.stdout.write

def mi():
	return map(int, inp().split())

def li():
	return list(mi())

def ii():
	return int(inp())

def main():
	for _ in range(ii()):
		(n, k) = mi()
		a = li()
		a.sort()
		ans = 0
		for i in range(1, n):
			while a[i] < k:
				a[i] += a[0]
				ans += 1
			if a[i] > k:
				ans -= 1
		print(ans)
main()


for i in range(int(input())):
	(a, b) = map(int, input().split())
	l = [int(x) for x in input().split()]
	l.sort()
	c = l[0]
	l.remove(c)
	p = 0
	for j in l:
		if b - j > 0:
			p = p + (b - j) // c
	print(p)


t = int(input())
for t0 in range(t):
	(n, k) = map(int, input().split())
	l = list(map(int, input().split()))
	l.sort(reverse=True)
	s = 0
	for i in range(n - 1):
		s += (k - l[i]) // l[-1]
	print(s)


for _ in range(int(input())):
	(n, k) = [int(i) for i in input().split()]
	arr = [int(i) for i in input().split()]
	m = min(arr)
	if max(arr) > k:
		print(0)
	else:
		s = 0
		for i in arr:
			s += (k - i) // m
		s -= (k - m) // m
		print(s)


t = int(input())
ns = []
for i in range(t):
	(n, k) = map(int, input().split())
	arr = list(map(int, input().split()))
	arr.sort()
	mn = arr[0]
	ans = 0
	for el in arr[1:]:
		ans += (k - el) // mn
	ns.append(ans)
for el in ns:
	print(el)


from sys import stdin
input = stdin.readline
for _ in range(int(input())):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	a.sort()
	ans = 0
	for x in a[1:]:
		ans += (k - x) // a[0]
	print(ans)


t = int(input())
ans = []
for i in range(t):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	ak = 10 ** 30
	kk = 0
	tmp = 0
	for j in range(n):
		if ak > a[j]:
			ak = a[j]
			kk = j
	for j in range(n):
		if j == kk:
			continue
		tmp += (k - a[j]) // ak
	ans.append(tmp)
print(*ans, sep='\n')


T = int(input())
for t in range(T):
	(n, k) = map(int, input().split())
	A = list(map(int, input().split()))
	minn = min(A)
	ans = 0
	for i in range(n):
		temp = (k - A[i]) // minn
		if temp > 0:
			ans += temp
	temp = (k - minn) // minn
	if temp > 0:
		ans -= temp
	print(ans)


def rl():
	return [int(x) for x in input().split()]

def arp(arr):
	return ' '.join([i for i in arr])
from operator import itemgetter
from math import ceil, floor
from collections import deque as dq
for t in range(int(input())):
	(n, k) = rl()
	arr = rl()
	arr.sort()
	mini = arr[0]
	ans = 0
	for i in range(1, n):
		ans += floor((k - arr[i]) / mini)
	print(ans)


def solve():
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	res = 0
	a.sort()
	for i in range(1, n):
		if k >= a[i]:
			res += (k - a[i]) // a[0]
	print(res)
	return

def main():
	T = int(input())
	for i in range(T):
		solve()
	return
main()


rw = int(input())
for wewq in range(rw):
	(n, k) = map(int, input().split())
	a = list(map(int, input().split()))
	ma = a[0]
	mi = 0
	f = 0
	for i in range(n):
		if ma > a[i]:
			mi = i
			ma = a[i]
	for i in range(n):
		if i != mi:
			f += (k - a[i]) // ma
	print(f)