AtCoder Beginner Contest 114 - 756

You are given an integer N. Among the divisors of N! (= 1 \times 2 \times ... \times N), how many Shichi-Go numbers (literally "Seven-Five numbers") are there?
Here, a Shichi-Go number is a positive integer that has exactly 75 divisors.

-----Note-----
When a positive integer A divides a positive integer B, A is said to a divisor of B.
For example, 6 has four divisors: 1, 2, 3 and 6.

-----Constraints-----
 - 1 \leq N \leq 100
 - N is an integer.

-----Input-----
Input is given from Standard Input in the following format:
N

-----Output-----
Print the number of the Shichi-Go numbers that are divisors of N!.

-----Sample Input-----
9

-----Sample Output-----
0

There are no Shichi-Go numbers among the divisors of 9! = 1 \times 2 \times ... \times 9 = 362880.

Difficulty: MEDIUM

Starter code:

Solutions:
import math
from collections import defaultdict
import numpy as np
n = int(input())
dic = defaultdict(lambda : 0)
for i in range(2, n + 1):
	sqrt = math.floor(i ** 0.5)
	for j in range(2, sqrt + 1):
		if not i % j:
			count = 0
			while i % j == 0:
				count += 1
				i //= j
			dic[j] += count
	if i > 1:
		dic[i] += 1
values = np.array(list(dic.values()))
v1 = len(values[values >= 2])
v2 = len(values[values >= 4])
v = v2 * (v2 - 1) // 2 * (v1 - 2)
v3 = len(values[values >= 24])
v += v3 * (v1 - 1)
v4 = len(values[values >= 14])
v += v4 * (v2 - 1)
v5 = len(values[values >= 74])
v += v5
print(v)


from collections import defaultdict
n = int(input())
factor_list = defaultdict(int)
for i in range(1, n + 1):
	p = 2
	t = i
	while p <= n ** 0.5 + 5:
		if t % p == 0:
			factor_list[p] += 1
			t //= p
		else:
			p += 1
	if t > 1:
		factor_list[t] += 1
nums = [0 for _ in range(1000)]
for (k, v) in factor_list.items():
	nums[v] += 1
for i in range(998, -1, -1):
	nums[i] += nums[i + 1]
print(nums[74] + nums[24] * (nums[2] - 1) + nums[14] * (nums[4] - 1) + nums[4] * (nums[4] - 1) * (nums[2] - 2) // 2)


n = int(input())

def nprf(m):
	pf = {}
	for i in range(2, m + 1):
		for j in range(2, i + 1):
			while i % j == 0:
				pf[j] = pf.get(j, 0) + 1
				i //= j
	return pf

def c(P, m):
	count = 0
	for i in P:
		if P[i] >= m - 1:
			count += 1
	return count
P = nprf(n)
f75 = c(P, 75)
f253 = c(P, 25) * (c(P, 3) - 1)
f155 = c(P, 15) * (c(P, 5) - 1)
f553 = int(c(P, 5) * (c(P, 5) - 1) * (c(P, 3) - 2) * 0.5)
print(f75 + f253 + f155 + f553)


from collections import Counter as c
from itertools import permutations as p

def fact(n):
	d = []
	for i in range(2, int(n ** 0.5) + 2):
		while n % i == 0:
			n //= i
			d.append(i)
	if n != 1:
		d.append(n)
	return c(d)
n = int(input())
d = c()
for i in range(1, n + 1):
	d += fact(i)
v = sum((1 for (i, j, k) in p(d.values(), 3) if i >= 2 and j >= 4 and (k >= 4))) // 2
v += sum((1 for (i, j) in p(d.values(), 2) if i >= 2 and j >= 24))
v += sum((1 for (i, j) in p(d.values(), 2) if i >= 4 and j >= 14))
v += sum((1 for i in d.values() if i >= 74))
print(v)


l = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97]
ans = 0
(l3, l5, l15, l25, l75) = (0, 0, 0, 0, 0)
n = int(input())
for i in l:
	temp = n
	c = 1
	while temp >= i:
		temp //= i
		c += temp
	if c >= 3:
		l3 += 1
	if c >= 5:
		l5 += 1
	if c >= 15:
		l15 += 1
	if c >= 25:
		l25 += 1
	if c >= 75:
		l75 += 1
ans += l75
ans += l25 * (l3 - 1)
ans += l15 * (l5 - 1)
ans += (l3 - 2) * l5 * (l5 - 1) // 2
print(ans)


from collections import Counter as c
from itertools import permutations as p

def fact(n):
	d = []
	for i in range(2, int(n ** 0.5) + 2):
		while n % i == 0:
			n //= i
			d.append(i)
	if n != 1:
		d.append(n)
	return c(d)
n = int(input())
d = c()
for i in range(1, n + 1):
	d += fact(i)
f = lambda n, x: sum((1 for i in p(d.values(), n) if all(map(lambda x, y: x >= y, i, x))))
print(f(3, (2, 4, 4)) // 2 + f(2, (2, 24)) + f(2, (4, 14)) + f(1, (74,)))


N = int(input())
prime = [2]
for j in range(3, 100):
	if all((j % i != 0 for i in prime)):
		prime.append(j)
N1 = 1
for i in range(1, N + 1):
	N1 *= i
prime1 = []
for j in prime:
	temp = 0
	while N1 % pow(j, temp) == 0:
		temp += 1
	prime1.append(temp - 1)

def num(m):
	return len(list(filter(lambda x: x >= m - 1, prime1)))
ans = num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) // 2 * (num(3) - 2)
print(ans)


N = int(input())
prime = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47]

def Count(x):
	res = 0
	tmp = N
	while tmp // x:
		tmp = tmp // x
		res += tmp
	return res
cnt = [Count(p) for p in prime]

def Sum(n):
	return sum([x >= n for x in cnt])
Ans = 0
Ans = Sum(74) + Sum(24) * (Sum(2) - 1) + Sum(14) * (Sum(4) - 1) + Sum(4) * (Sum(4) - 1) * (Sum(2) - 2) // 2
print(Ans)


from collections import Counter
N = int(input())
fac = []
for n in range(2, N + 1):
	for x in range(2, int(n ** 0.5) + 2):
		while n % x == 0:
			fac.append(x)
			n //= x
	if n > 1:
		fac.append(n)
c = Counter(fac)
cn = [len(list(filter(lambda x: x >= i, c.values()))) for i in range(75)]
print(cn[74] + cn[24] * (cn[2] - 1) + cn[14] * (cn[4] - 1) + cn[4] * (cn[4] - 1) * (cn[2] - 2) // 2)


n = int(input())
p = (n + 1) * [0]
for i in range(2, n + 1):
	now = i
	for j in range(2, i + 1):
		while now % j == 0:
			p[j] += 1
			now //= j

def cnt(m):
	return len(list(filter(lambda x: x >= m, p)))
ans = 0
ans += cnt(74)
ans += cnt(24) * (cnt(2) - 1)
ans += cnt(14) * (cnt(4) - 1)
ans += cnt(4) * (cnt(4) - 1) * (cnt(2) - 2) // 2
print(ans)


n = int(input())
pdic = [0] * 101
for i in range(2, n + 1):
	cur = i
	for j in range(2, i + 1):
		while cur % j == 0:
			pdic[j] += 1
			cur //= j

def num(m):
	return len(list(filter(lambda x: x >= m - 1, pdic)))
print(num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2)


n = int(input())
C = [0] * (n + 1)
for i in range(2, n + 1):
	tmp = i
	for j in range(2, i + 1):
		while tmp % j == 0:
			C[j] += 1
			tmp //= j

def num(n):
	return len(list(filter(lambda x: x >= n - 1, C)))
print(num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2)


n = int(input())
c = [0] * (n + 1)
for i in range(2, n + 1):
	num = i
	for j in range(2, i + 1):
		while num % j == 0:
			c[j] += 1
			num //= j

def cnt(x):
	count = 0
	for i in range(n + 1):
		if c[i] >= x - 1:
			count += 1
	return count
print(cnt(75) + cnt(25) * (cnt(3) - 1) + cnt(15) * (cnt(5) - 1) + cnt(5) * (cnt(5) - 1) * (cnt(3) - 2) // 2)


import sys

def get_pfn(N):
	e = [0] * (N + 1)
	for i in range(2, N + 1):
		cur = i
		for j in range(2, i + 1):
			while cur % j == 0:
				e[j] += 1
				cur //= j
	return e

def num(n, e):
	return len(list(filter(lambda x: x >= n - 1, e)))

def main():
	input = sys.stdin.readline
	N = int(input())
	e = get_pfn(N)
	print(num(75, e) + num(25, e) * (num(3, e) - 1) + num(15, e) * (num(5, e) - 1) + num(5, e) * (num(5, e) - 1) * (num(3, e) - 2) // 2)
main()


n = int(input())
if n < 10:
	print(0)
	exit()
e = [0 for _ in range(n + 1)]
for i in range(2, n + 1):
	temp = i
	for j in range(2, i + 1):
		while temp % j == 0:
			e[j] += 1
			temp //= j
a = [0 for _ in range(75)]
for i in range(n + 1):
	for j in range(min(75, e[i] + 1)):
		a[j] += 1
ans = a[74] + a[24] * (a[2] - 1) + a[14] * (a[4] - 1) + a[4] * (a[4] - 1) * (a[2] - 2) // 2
print(ans)


from math import sqrt
from bisect import bisect_left as bi
n = int(input())
(x, z) = ([0] * 98, [])
for i in range(2, n + 1):
	m = i
	while 1:
		f = 0
		for j in range(2, int(sqrt(m)) + 1):
			if m % j == 0:
				x[j] += 1
				f = 1
				break
		if f:
			m //= j
		else:
			x[m] += 1
			break
for i in x[::-1]:
	if i > 1:
		z.append(i)
p = len(z)
print(p - bi(z, 74) + max((p - bi(z, 24)) * (p - bi(z, 2) - 1), 0) + max((p - bi(z, 14)) * (p - bi(z, 4) - 1), 0) + max((p - bi(z, 4)) * (p - bi(z, 4) - 1) * (p - bi(z, 2) - 2) // 2, 0))


from collections import Counter
from itertools import permutations
n = int(input())

def factorization(n):
	p = 2
	fcr = []
	while p * p <= n:
		while n % p == 0:
			fcr.append(p)
			n //= p
		p += 1
	if n > 1:
		fcr.append(n)
	return fcr
fcr_l = []
for i in range(1, n + 1):
	fcr = factorization(i)
	fcr_l += fcr
c = Counter(fcr_l)
fcr_st = set(fcr_l)
ans = []
for (p, q, r) in permutations(fcr_st, 3):
	if c[p] >= 74:
		ans.append(p ** 74)
	if c[p] >= 24 and c[q] >= 2:
		ans.append(p ** 24 * q ** 2)
	if c[p] >= 14 and c[q] >= 4:
		ans.append(p ** 14 * q ** 4)
	if c[p] >= 4 and c[q] >= 4 and (c[r] >= 2):
		ans.append(p ** 4 * q ** 4 * r ** 2)
print(len(set(ans)))


import math
import queue
import bisect
from collections import deque, defaultdict
import heapq as hpq
from sys import stdin, setrecursionlimit
ipt = stdin.readline
setrecursionlimit(10 ** 7)
mod = 10 ** 9 + 7

def main():
	n = int(ipt())
	d = defaultdict(int)

	def primes(n):
		if n == 1:
			return []
		else:
			tbl = [True] * (n + 1)
			pri = [2]
			for i in range(2, n + 1, 2):
				tbl[i] = False
			k = 3
			while k <= n:
				if tbl[k]:
					pri.append(k)
					for i in range(k, n + 1, k):
						tbl[i] = False
				k += 2
			return pri
	p = primes(n)
	for i in range(2, n + 1):
		ii = i
		for j in p:
			while True:
				if ii % j == 0:
					d[j] += 1
					ii //= j
				else:
					break
			if ii == 1:
				break
	d2 = 0
	d4 = 0
	d14 = 0
	d24 = 0
	d74 = 0
	for i in list(d.values()):
		if i >= 2:
			d2 += 1
			if i >= 4:
				d4 += 1
				if i >= 14:
					d14 += 1
					if i >= 24:
						d24 += 1
						if i >= 74:
							d74 += 1
	print(d4 * (d4 - 1) * (d2 - 2) // 2 + d14 * (d4 - 1) + d24 * (d2 - 1) + d74)
	return None

def __starting_point():
	main()
__starting_point()


from collections import Counter
N = int(input())
c = Counter()
for n in range(2, N + 1):
	i = 2
	while i ** 2 <= n:
		count = 0
		while n % i == 0:
			n //= i
			count += 1
		if count != 0:
			c[i] += count
		i += 1
	if n > 1:
		c[n] += 1

def num(m):
	return len(list(filter(lambda x: x >= m - 1, c.values())))
ans = 0
ans += num(75)
ans += (num(5) - 1) * num(15)
ans += (num(3) - 1) * num(25)
ans += (num(3) - 2) * num(5) * (num(5) - 1) // 2
print(ans)


from collections import defaultdict
primes = list(range(2, 101))
for i in range(len(primes)):
	if primes[i]:
		j = i
		j += primes[i]
		while j < len(primes):
			primes[j] = None
			j += primes[i]
primes = [p for p in primes if p]
N = int(input())
fact = defaultdict(int)
for p in primes:
	i = p
	while i <= N:
		fact[p] += N // i
		i *= p
f2 = set()
f4 = set()
f14 = set()
f24 = set()
f74 = set()
for p in fact:
	if fact[p] >= 2:
		f2.add(p)
	if fact[p] >= 4:
		f4.add(p)
	if fact[p] >= 14:
		f14.add(p)
	if fact[p] >= 24:
		f24.add(p)
	if fact[p] >= 74:
		f74.add(p)
ans = 0
ans += len(f74)
ans += len(f24) * (len(f2) - 1)
ans += len(f14) * (len(f4) - 1)
ans += (len(f2) - 2) * len(f4) * (len(f4) - 1) // 2
print(ans)


n = int(input())
is_prime = [True for _ in range(100)]
is_prime[0] = is_prime[1] = False
for i in range(100):
	if not is_prime[i]:
		continue
	for j in range(i * i, 100, i):
		if not is_prime[j]:
			is_prime[j] = False
factor = [0 for _ in range(100)]
for i in range(2, n + 1):
	for j in range(2, 100):
		if is_prime[j]:
			while i % j == 0:
				factor[j] += 1
				i //= j
fs = []
for i in range(100):
	if factor[i] != 0:
		fs.append(factor[i])
m = len(fs)
ans = [0 for _ in range(4)]
for i in range(m):
	for j in range(m):
		for k in range(m):
			if i != j and j != k and (k != i):
				if fs[i] >= 4 and fs[j] >= 4 and (fs[k] >= 2):
					ans[0] += 1
for i in range(m):
	if fs[i] >= 74:
		ans[1] += 1
for i in range(m):
	for j in range(m):
		if i != j:
			if fs[i] >= 2 and fs[j] >= 24:
				ans[2] += 1
for i in range(m):
	for j in range(m):
		if i != j:
			if fs[i] >= 4 and fs[j] >= 14:
				ans[3] += 1
Ans = ans[0] // 2 + ans[1] + ans[2] + ans[3]
print(Ans)


N = int(input())
e = [0] * 101
for n in range(2, N + 1):
	cur = n
	for i in range(2, n + 1):
		while cur % i == 0:
			e[i] += 1
			cur //= i
ans = 0
(ov74, ov24, ov14, ov4, ov2) = (0, 0, 0, 0, 0)
for ei in e:
	if ei >= 2:
		ov2 += 1
	if ei >= 4:
		ov4 += 1
	if ei >= 14:
		ov14 += 1
	if ei >= 24:
		ov24 += 1
	if ei >= 74:
		ov74 += 1
ans += ov24 * (ov2 - 1)
ans += ov4 * (ov4 - 1) * (ov2 - 2) // 2
ans += ov14 * (ov4 - 1)
ans += ov74
print(ans)


N = int(input())
P = [1] * (N + 1)
for i in range(1, N + 1):
	n = i
	for j in range(2, N + 1):
		while n % j == 0:
			P[j] += 1
			n //= j
P = [p for p in P if p > 1]
N = len(P) - 1
cnt = 0
B = [1, 3, 5, 15, 25, 75]

def f(k, d):
	global N, P, cnt, B
	if d == 75:
		cnt += 1
		return
	elif d > 75 or k > N:
		return
	for i in range(1, P[k] + 1):
		if i in B:
			f(k + 1, d * i)
f(0, 1)
print(cnt)


def num(v):
	return len(tuple(filter(lambda x: x >= v - 1, e)))
n = int(input())
e = [0] * (n + 1)
for i in range(2, n + 1):
	b = i
	j = 2
	while j * j <= i:
		while b % j == 0:
			b //= j
			e[j] += 1
		j += 1
	if b > 1:
		e[b] += 1
e = tuple(filter(lambda x: x > 0, e))
ans = 0
ans += num(75)
ans += num(25) * (num(3) - 1)
ans += num(15) * (num(5) - 1)
ans += num(5) * (num(5) - 1) // 2 * (num(3) - 2)
print(ans)


def factorize(n):
	if n == 1:
		raise 'n >= 2'
	factor = {}
	div = 2
	while True:
		if n % div == 0:
			n //= div
			factor[div] = factor.get(div, 0) + 1
			if n == 1:
				return factor
		else:
			div += 1
n = int(input())
if n <= 9:
	print(0)
	return
import math
product = math.prod(range(1, n + 1))
d = factorize(product)
factor = list(d.items())
ans = 0
for i in range(len(factor)):
	for j in range(i + 1, len(factor)):
		for k in range(len(factor)):
			if factor[i][1] >= 4 and factor[j][1] >= 4 and (factor[k][1] >= 2) and (i != j) and (j != k) and (k != i):
				ans += 1
for i in range(len(factor)):
	for j in range(len(factor)):
		if factor[i][1] >= 4 and factor[j][1] >= 14 and (i != j):
			ans += 1
for i in range(len(factor)):
	for j in range(len(factor)):
		if factor[i][1] >= 2 and factor[j][1] >= 24 and (i != j):
			ans += 1
for i in range(len(factor)):
	if factor[i][1] >= 74:
		ans += 1
print(ans)


N = int(input())
from operator import mul
from functools import reduce

def cmb(n, r):
	r = min(n - r, r)
	if r == 0:
		return 1
	over = reduce(mul, list(range(n, n - r, -1)))
	under = reduce(mul, list(range(1, r + 1)))
	return over // under
from collections import defaultdict

def factorization(n):
	arr = []
	temp = n
	for i in range(2, int(-(-n ** 0.5 // 1)) + 1):
		if temp % i == 0:
			cnt = 0
			while temp % i == 0:
				cnt += 1
				temp //= i
			arr.append([i, cnt])
	if temp != 1:
		arr.append([temp, 1])
	if arr == []:
		arr.append([n, 1])
	return arr
count = 1
D = defaultdict(int)
for i in range(1, N + 1):
	f = factorization(i)
	for t in f:
		(num, con) = t
		D[num] += con
threes = 0
fives = 0
num_15 = 0
num_25 = 0
num_75 = 0
for v in list(D.values()):
	if v >= 2:
		threes += 1
	if v >= 4:
		fives += 1
	if v >= 14:
		num_15 += 1
	if v >= 24:
		num_25 += 1
	if v >= 74:
		num_75 += 1
ans = (threes - fives) * fives * (fives - 1) // 2
if fives >= 3:
	ans += fives * (fives - 1) * (fives - 2) // 2
ans += num_75
ans += num_15 * (fives - 1)
ans += num_25 * (threes - 1)
print(ans)


import sys
from collections import Counter
read = sys.stdin.read
readline = sys.stdin.readline
readlines = sys.stdin.readlines
sys.setrecursionlimit(10 ** 9)
INF = 1 << 60
MOD = 1000000007

def prime_factorize(n):
	a = Counter()
	while n % 2 == 0:
		a[2] += 1
		n //= 2
	f = 3
	while f * f <= n:
		if n % f == 0:
			a[f] += 1
			n //= f
		else:
			f += 2
	if n != 1:
		a[n] += 1
	return a

def com(n, r):
	if n < r or n < 0 or r < 0:
		return 0
	r = min(r, n - r)
	numer = denom = 1
	for i in range(n - r + 1, n + 1):
		numer = numer * i
	for i in range(1, r + 1):
		denom = denom * i
	return numer // denom

def main():
	N = int(readline())
	prime = Counter()
	for n in range(1, N + 1):
		prime.update(prime_factorize(n))
	C = [0] * 101
	for v in list(prime.values()):
		C[v] += 1
	for i in range(99, -1, -1):
		C[i] += C[i + 1]
	ans = 0
	ans += (C[2] - 2) * com(C[4], 2)
	ans += (C[2] - 1) * C[24]
	ans += (C[4] - 1) * C[14]
	ans += C[74]
	print(ans)
	return

def __starting_point():
	main()
__starting_point()


n = int(input())
c = [0] * (n + 1)
for i in range(2, n + 1):
	j = 2
	while j * j <= i:
		while i % j == 0:
			c[j] += 1
			i //= j
		j += 1
	if i > 1:
		c[i] += 1
f = lambda x: sum((y + 1 >= x for y in c))
print(f(75) + f(25) * (f(3) - 1) + f(15) * (f(5) - 1) + f(5) * (f(5) - 1) // 2 * (f(3) - 2))


from collections import Counter
from math import factorial

def prime_factorize(n):
	a = []
	while n % 2 == 0:
		a.append(2)
		n //= 2
	f = 3
	while f * f <= n:
		if n % f == 0:
			a.append(f)
			n //= f
		else:
			f += 2
	if n != 1:
		a.append(n)
	return a

def prime_factoring(n):
	from collections import Counter
	a = prime_factorize(n)
	return Counter(a)
N = int(input())
fac = factorial(N)
List = list(prime_factoring(fac).values())

def num(m):
	return len(list([x for x in List if x >= m - 1]))
print(num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2)


def check(m, e):
	return len(list(filter(lambda x: x >= m - 1, e)))

def main():
	N = int(input())
	e = [0] * (N + 1)
	for i in range(2, N + 1):
		ii = i
		for j in range(2, i + 1):
			while ii % j == 0:
				e[j] += 1
				ii //= j
	print(check(75, e) + check(25, e) * (check(3, e) - 1) + check(15, e) * (check(5, e) - 1) + check(5, e) * (check(5, e) - 1) * (check(3, e) - 2) // 2)
main()


def soinsubunkai(n):
	arr = []
	temp = n
	for i in range(2, int(-(-n ** 0.5 // 1)) + 1):
		if temp % i == 0:
			cnt = 0
			while temp % i == 0:
				cnt += 1
				temp //= i
			arr.append([i, cnt])
	if temp != 1:
		arr.append([temp, 1])
	if arr == []:
		arr.append([n, 1])
	return arr

def main():
	N = int(input())
	soinsu = {}
	for i in range(2, N + 1):
		i_soinsu = soinsubunkai(i)
		for (p, idx) in i_soinsu:
			if p not in soinsu:
				soinsu[p] = idx
			else:
				soinsu[p] += idx
	(n_75, n_25, n_15, n_5, n_3) = (0, 0, 0, 0, 0)
	for v in list(soinsu.values()):
		if v >= 74:
			n_75 += 1
		if v >= 24:
			n_25 += 1
		if v >= 14:
			n_15 += 1
		if v >= 4:
			n_5 += 1
		if v >= 2:
			n_3 += 1
	n_3_5_5 = n_5 * (n_5 - 1) * (n_3 - 2) // 2
	n_5_15 = n_15 * (n_5 - 1)
	n_3_25 = n_25 * (n_3 - 1)
	return n_3_5_5 + n_5_15 + n_3_25 + n_75
print(main())


import copy

def fact(n, s):
	return len(list(filter(lambda x: x >= n - 1, s)))
n = int(input())
s = [0] * (n + 1)
for i in range(2, n + 1):
	a = copy.deepcopy(i)
	for j in range(2, a + 1):
		while a % j == 0:
			s[j] += 1
			a //= j
b = fact(5, s)
print(max(0, fact(75, s) + fact(25, s) * (fact(3, s) - 1) + fact(15, s) * (fact(5, s) - 1) + b * (b - 1) * (fact(3, s) - 2) // 2))


import itertools
primes = [2, 3, 5, 7] + [x for x in range(10, 100) if x % 2 and x % 3 and x % 5 and x % 7]

def fact_ord(p, n):
	return n // p + fact_ord(p, n // p) if n else 0
N = int(input())
order = [fact_ord(p, N) for p in primes]
arr = [0] * 80
arr[1] = 1
for e in order:
	temp = [0] * 80
	for (ee, j) in itertools.product(range(e + 1), range(80)):
		y = min((ee + 1) * j, 79)
		temp[y] += arr[j]
	arr = temp
answer = arr[75]
print(answer)


n = int(input())
primes = [0 for i in range(n + 1)]
for i in range(2, n + 1):
	cur = i
	for j in range(2, i + 1):
		while cur % j == 0:
			cur = cur // j
			primes[j] += 1

def num(m):
	res = 0
	for i in primes:
		if i >= m - 1:
			res += 1
	return res
print(num(75) + (num(5) - 1) * num(5) * (num(3) - 2) // 2 + num(15) * (num(5) - 1) + num(25) * (num(3) - 1))


n = int(input())

def f_pf(n):
	pf = {}
	for i in range(2, n + 1):
		for j in range(2, i + 1):
			while i % j == 0:
				pf[j] = pf.get(j, 0) + 1
				i //= j
	return pf

def cnt(x):
	cnt = 0
	for v in f_pf(n).values():
		if v >= x - 1:
			cnt += 1
	return cnt
ans = cnt(75) + cnt(25) * (cnt(3) - 1) + cnt(15) * (cnt(5) - 1) + cnt(5) * (cnt(5) - 1) * (cnt(3) - 2) // 2
print(ans)


n = int(input())
pf = {}
for m in range(1, n + 1):
	for i in range(2, int(m ** 0.5) + 1):
		while m % i == 0:
			pf[i] = pf.get(i, 0) + 1
			m //= i
	if m > 1:
		pf[m] = pf.get(m, 0) + 1
ans = 0
for (k, v) in pf.items():
	if v >= 74:
		ans += 1
	if v >= 24:
		for (s, t) in pf.items():
			if s != k and t >= 2:
				ans += 1
	if v >= 14:
		for (s, t) in pf.items():
			if s != k and t >= 4:
				ans += 1
	if v >= 4:
		for (s, t) in pf.items():
			if s > k and t >= 4:
				for (f, g) in pf.items():
					if f != s and f != k and (g >= 2):
						ans += 1
print(ans)


N = int(input())
from collections import Counter

def factorize(n):
	d = Counter()
	m = 2
	while m * m <= n:
		while n % m == 0:
			n //= m
			d[m] += 1
		m += 1
	if n > 1:
		d[n] += 1
	return d
fac = Counter()
for n in range(1, N + 1):
	fac += factorize(n)
ans = 0
v4 = v2 = 0
for v in fac.values():
	if v >= 4:
		v4 += 1
	elif v >= 2:
		v2 += 1
t = v4 * (v4 - 1) // 2 * (v4 - 2 + v2)
if t > 0:
	ans += t
v24 = v2 = 0
for v in fac.values():
	if v >= 24:
		v24 += 1
	elif v >= 2:
		v2 += 1
t = v24 * (v24 - 1 + v2)
ans += t
v14 = v4 = 0
for v in fac.values():
	if v >= 14:
		v14 += 1
	elif v >= 4:
		v4 += 1
t = v14 * (v14 - 1 + v4)
ans += t
v74 = 0
for v in fac.values():
	if v >= 74:
		v74 += 1
ans += v74
print(ans)


N = [int(_) for _ in input().split()][0]
e = [0] * (N + 1)
for i in range(2, N + 1):
	tmp = i
	for j in range(2, i + 1):
		if tmp <= 1:
			break
		while tmp % j == 0:
			e[j] += 1
			tmp //= j
dp = [[0] * 76 for _ in range(N + 1)]
dp[0][1] = 1
for i in range(1, N + 1):
	for j in range(e[i] + 1):
		for k in range(75 + 1):
			if k * (j + 1) > 75:
				break
			if dp[i - 1][k] > 0:
				dp[i][k * (j + 1)] += dp[i - 1][k]
print(dp[N][75])


def f(p, N):
	res = 0
	while N >= p:
		N //= p
		res += N
	return res
N = int(input())
ps = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47]
A = [len([p for p in ps if f(p, N) >= k]) for k in [2, 4, 14, 24, 74]]
(a, b, c, d, e) = (A[0], A[1], A[2], A[3], A[4])
ans = 0
ans += b * (b - 1) // 2 * (a - 2)
ans += d * (a - 1)
ans += c * (b - 1)
ans += e
print(ans)


N = int(input())
e = [0] * (N + 1)
for i in range(N + 1):
	cur = i
	for j in range(2, i + 1):
		while cur % j == 0:
			e[j] += 1
			cur = cur // j

def num(m):
	tmp = 0
	for i in range(N + 1):
		if e[i] >= m:
			tmp += 1
	return tmp
print(num(74) + num(24) * (num(2) - 1) + num(4) * (num(4) - 1) * (num(2) - 2) // 2 + num(14) * (num(4) - 1))


n = int(input())

def nprf(n):
	pf = {}
	for i in range(2, n + 1):
		for j in range(2, i + 1):
			while i % j == 0:
				if not j in pf:
					pf[j] = 0
				pf[j] += 1
				i //= j
	return pf
pf = nprf(n)

def f(n):
	count = 0
	for v in pf.values():
		if v >= n - 1:
			count += 1
	return count
f1 = f(75)
f2 = f(25) * (f(3) - 1)
f3 = f(15) * (f(5) - 1)
f4 = f(5) * (f(5) - 1) // 2 * (f(3) - 2)
print(f1 + f2 + f3 + f4)


n = int(input())
primelist = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47]
ll = [0, 0, 0, 0, 0]
for i in range(len(primelist)):
	a = primelist[i]
	t = n
	po = 0
	while t > 0:
		t = int(t / a)
		po += t
	if po >= 74:
		ll[4] += 1
	if po >= 24:
		ll[3] += 1
	if po >= 14:
		ll[2] += 1
	if po >= 4:
		ll[1] += 1
	if po >= 2:
		ll[0] += 1
ans = ll[4] + ll[3] * (ll[0] - 1) + ll[2] * (ll[1] - 1) + ll[1] * (ll[1] - 1) * (ll[0] - 2) / 2
print(int(ans))


from collections import Counter, defaultdict, deque
from heapq import heappop, heappush
from bisect import bisect_left, bisect_right
import sys, math, itertools, fractions, pprint
sys.setrecursionlimit(10 ** 8)
mod = 10 ** 9 + 7
INF = float('inf')

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

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

def conb(n, r):
	if n < r:
		return 0
	return math.factorial(n) // (math.factorial(n - r) * math.factorial(r))

def prime_factorize(n):
	if n == 1:
		return [1]
	a = []
	while n % 2 == 0:
		a.append(2)
		n //= 2
	f = 3
	while f * f <= n:
		if n % f == 0:
			a.append(f)
			n //= f
		else:
			f += 2
	if n != 1:
		a.append(n)
	return a
n = inp()
d = defaultdict(int)
for i in range(1, n + 1):
	for x in prime_factorize(i):
		d[x] += 1
valist = list(d.values())
c = [2, 4, 14, 24, 74]
cnt = [0] * 5
for x in valist:
	if x >= 74:
		cnt[4] += 1
	elif x >= 24:
		cnt[3] += 1
	elif x >= 14:
		cnt[2] += 1
	elif x >= 4:
		cnt[1] += 1
	elif x >= 2:
		cnt[0] += 1
res = 0
a = sum(cnt[1:])
b = cnt[0]
res += conb(a, 3) * 3 + conb(a, 2) * b
a = sum(cnt[2:])
b = cnt[1]
res += a * (a - 1) + a * b
a = sum(cnt[3:])
b = sum(cnt[:3])
res += a * (a - 1) + a * b
res += cnt[4]
print(res)


n = int(input())
f = [0] * (n + 1)
for i in range(2, n + 1):
	a = i
	for j in range(2, i + 1):
		while a % j == 0:
			f[j] += 1
			a //= j

def number(m):
	c = 0
	for i in range(n):
		if f[i] >= m - 1:
			c += 1
	return c
print(number(75) + number(25) * (number(3) - 1) + number(15) * (number(5) - 1) + number(5) * (number(5) - 1) * (number(3) - 2) // 2)


n = int(input())
d = dict()
for m in range(1, n + 1):
	while m > 1:
		for i in range(2, int(m ** 0.5) + 1):
			if m % i == 0:
				break
		else:
			i = m
		d[i] = d.get(i, 0) + 1
		m /= i

def num(n):
	return len(list(filter(lambda x: x >= n, d.values())))
print(num(74) + num(24) * (num(2) - 1) + num(14) * (num(4) - 1) + num(4) * (num(4) - 1) * (num(2) - 2) // 2)


import collections
n = int(input())
div = []
for i in range(1, n + 1):
	for j in range(2, int(n ** 0.5) + 1):
		while i % j == 0:
			div.append(j)
			i //= j
	if i > 1:
		div.append(i)
c = collections.Counter(div)
(n2, n4, n14, n24, n74) = (0, 0, 0, 0, 0)
for (k, v) in list(c.items()):
	if v >= 2:
		n2 += 1
	if v >= 4:
		n4 += 1
	if v >= 14:
		n14 += 1
	if v >= 24:
		n24 += 1
	if v >= 74:
		n74 += 1
ans = n74 + n24 * (n2 - 1) + n14 * (n4 - 1) + n4 * (n4 - 1) * (n2 - 2) // 2
print(ans)


n = int(input())
if n == 1:
	print(0)
	return
a = [0] * (n + 1)

def pf(n):
	a = []
	while n % 2 == 0:
		a.append(2)
		n //= 2
	f = 3
	while f * f <= n:
		if n % f == 0:
			a.append(f)
			n //= f
		else:
			f += 2
	if n != 1:
		a.append(n)
	return a
for i in range(2, n + 1):
	x = pf(i)
	for j in x:
		a[j] += 1
b = [0] * 5
for i in a:
	if i >= 74:
		b[4] += 1
	elif i >= 24:
		b[3] += 1
	elif i >= 14:
		b[2] += 1
	elif i >= 4:
		b[1] += 1
	elif i >= 2:
		b[0] += 1
for i in range(4):
	b[3 - i] += b[4 - i]
ans = 0
ans += b[1] * (b[1] - 1) // 2 * (b[0] - 2)
ans += b[2] * (b[1] - 1)
ans += b[3] * (b[0] - 1)
ans += b[4]
print(ans)


def f(n):
	return len(list(filter(lambda x: x >= n - 1, l)))
n = int(input())
l = [0] * (n + 1)
for i in range(2, n + 1):
	cur = i
	for j in range(2, i + 1):
		while cur % j == 0:
			l[j] += 1
			cur //= j
print(f(75) + f(25) * (f(3) - 1) + f(15) * (f(5) - 1) + f(5) * (f(5) - 1) * (f(3) - 2) // 2)


from collections import Counter
N = int(input())

def prime_factorization(n):
	table = []
	for x in range(2, int(n ** 0.5) + 1):
		while n % x == 0:
			table.append(x)
			n //= x
	if n > 1:
		table.append(n)
	return table
T = []
for n in range(1, N + 1):
	T.extend(prime_factorization(n))
C = Counter(T)

def num(x):
	ret = sum([cnt >= x - 1 for cnt in C.values()])
	return ret
ans = num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) // 2 * (num(3) - 2) + num(75)
print(ans)


n = int(input())
if n == 1:
	print(0)
	return
primes = [True] * (n + 1)
primes[0] = False
primes[1] = False
for i in range(2, n + 1):
	if primes[i]:
		for j in range(i * 2, n + 1, i):
			primes[j] = False
primes = [i for (i, j) in enumerate(primes) if j]
factors = {2: 0, 4: 0, 14: 0, 24: 0, 74: 0}
for i in primes:
	tmp = 0
	j = i
	while j <= n:
		tmp += n // j
		j *= i
	for k in factors:
		if tmp >= k:
			factors[k] += 1
ans = factors[4] * (factors[4] - 1) * (factors[2] - 2) // 2
ans += factors[14] * (factors[4] - 1)
ans += factors[24] * (factors[2] - 1)
ans += factors[74]
print(ans)


N = int(input())
e = [0] * (N + 1)
for i in range(2, N + 1):
	cur = i
	for j in range(2, i + 1):
		while cur % j == 0:
			e[j] += 1
			cur //= j

def num(M: int):
	return len(tuple(filter(lambda x: x >= M - 1, e)))
answer = num(75)
answer += num(25) * (num(3) - 1)
answer += num(15) * (num(5) - 1)
answer += num(5) * (num(5) - 1) * (num(3) - 2) // 2
print(answer)


N = int(input())
d = dict()
for n in range(2, N + 1):
	x = 2
	while n > 1:
		if n % x == 0:
			n //= x
			if x in d.keys():
				d[x] += 1
			else:
				d[x] = 1
		else:
			x += 1

def f(x):
	n = 0
	for i in d.values():
		if i >= x:
			n += 1
	return n
ans = f(74) + f(24) * (f(2) - 1) + f(14) * (f(4) - 1) + f(4) * (f(4) - 1) // 2 * (f(2) - 2)
print(ans)


def factoring(n):
	for i in range(2, n + 1):
		while n % i == 0:
			n //= i
			d[i] += 1
N = int(input())
d = [0] * (N + 1)
for n in range(2, N + 1):
	factoring(n)

def num(n):
	return len([e for e in d if e >= n])
ans = num(74) + num(14) * (num(4) - 1) + num(24) * (num(2) - 1) + num(4) * (num(4) - 1) * (num(2) - 2) // 2
print(ans)


N = int(input())
e = [0] * (N + 1)
for i in range(2, N + 1):
	cur = i
	for j in range(2, i + 1):
		while cur % j == 0:
			e[j] += 1
			cur //= j

def num(m):
	return len(list(filter(lambda x: x >= m - 1, e)))
print(num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2)


n = int(input())
cnt = [1] * 101
for i in range(2, n + 1):
	for j in range(2, n + 1):
		while i % j == 0:
			i /= j
			cnt[j] += 1
san = 0
go = 0
jugo = 0
nijugo = 0
shitigo = 0
for i in range(2, 101):
	if cnt[i] >= 3:
		san += 1
	if cnt[i] >= 5:
		go += 1
	if cnt[i] >= 15:
		jugo += 1
	if cnt[i] >= 25:
		nijugo += 1
	if cnt[i] >= 75:
		shitigo += 1
print(shitigo + nijugo * (san - 1) + jugo * (go - 1) + go * (go - 1) // 2 * (san - 2))


import numpy as np

def prime_factorize(N):
	exponent = 0
	while N % 2 == 0:
		exponent += 1
		N //= 2
	if exponent:
		factorization = [[2, exponent]]
	else:
		factorization = []
	i = 1
	while i * i <= N:
		i += 2
		if N % i:
			continue
		exponent = 0
		while N % i == 0:
			exponent += 1
			N //= i
		factorization.append([i, exponent])
	if N != 1:
		factorization.append([N, 1])
	assert N != 0, 'zero'
	return factorization
factors = [0] * 100
N = int(input())
for i in range(1, N + 1):
	for (p, n) in prime_factorize(i):
		factors[p] += n
factors = np.array(factors)
ov2 = len(factors[factors >= 2])
ov4 = len(factors[factors >= 4])
ov14 = len(factors[factors >= 14])
ov24 = len(factors[factors >= 24])
ov74 = len(factors[factors >= 74])
ans = 0
ans += (ov4 - 2) * ov4 * (ov4 - 1) // 2 + (ov2 - ov4) * ov4 * (ov4 - 1) // 2
ans += (ov4 - ov14) * ov14 + ov14 * (ov14 - 1)
ans += (ov2 - ov24) * ov24 + ov24 * (ov24 - 1)
ans += ov74
print(ans)


N = int(input())
p = [0] * (N + 1)
for i in range(2, N + 1):
	for j in range(2, i + 1):
		cnt = 0
		while i % j == 0:
			cnt += 1
			i //= j
		p[j] += cnt

def get_sum(n):
	return len(list(filter(lambda x: x >= n - 1, p)))
print(get_sum(75) + get_sum(25) * (get_sum(3) - 1) + get_sum(15) * (get_sum(5) - 1) + get_sum(5) * (get_sum(5) - 1) * (get_sum(3) - 2) // 2)


n = int(input())
p = [0] * (n + 1)
for i in range(2, n + 1):
	for j in range(2, n + 1):
		while i % j == 0:
			p[j] += 1
			i //= j
(a, b, c, e, d) = (0, 0, 0, 0, 0)
for prime in p:
	if prime >= 74:
		a += 1
	if prime >= 24:
		b += 1
	if prime >= 14:
		c += 1
	if prime >= 4:
		d += 1
	if prime >= 2:
		e += 1
print(a + b * (e - 1) + c * (d - 1) + (e - 2) * d * (d - 1) // 2)


from collections import Counter, defaultdict
N = int(input())

def createPrimeList(N, isTable=True):
	isPrime = [True] * (N + 1)
	isPrime[0] = False
	isPrime[1] = False
	for i in range(2, N):
		if not isPrime[i]:
			continue
		for p in range(i * 2, N, i):
			isPrime[p] = False
	return isPrime if isTable else [i for i in range(2, N) if isPrime[i]]
primeList = createPrimeList(100, False)

def primeFactorization(N):
	primes = Counter()
	for p in primeList:
		while N % p == 0:
			N //= p
			primes[p] += 1
	return primes
primes = Counter()
for i in range(1, N + 1):
	primes += primeFactorization(i)
cnt = defaultdict(int)
for c in list(primes.values()):
	c += 1
	for d in (3, 5, 15, 25, 75):
		if c >= d:
			cnt[d] += 1
ans = 0
ans += cnt[5] * (cnt[5] - 1) * (cnt[3] - 2) // 2
ans += cnt[25] * (cnt[3] - 1)
ans += cnt[15] * (cnt[5] - 1)
ans += cnt[75]
print(ans)


n = int(input())
N = 1
for i in range(n):
	N *= i + 1
a = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97]
l = [0 for i in range(len(a))]
k = 0
for i in a:
	tmp = N
	while True:
		if tmp % i == 0:
			l[k] += 1
			tmp = tmp // i
		else:
			k += 1
			break
up74 = len([i for i in l if i >= 74])
up24 = len([i for i in l if i >= 24])
up14 = len([i for i in l if i >= 14])
up4 = len([i for i in l if i >= 4])
up2 = len([i for i in l if i >= 2])
print(up74 + up24 * (up2 - 1) + up14 * (up4 - 1) + up4 * (up4 - 1) // 2 * (up2 - 2))


N = int(input())
d = {}
for n in range(2, N + 1):
	i = 2
	while i <= n:
		while n % i == 0:
			n //= i
			if i not in d:
				d[i] = 0
			d[i] += 1
		i += 1
ans_d = {3: 0, 5: 0, 15: 0, 25: 0, 75: 0}
for p in d:
	for n in ans_d:
		if d[p] >= n - 1:
			ans_d[n] += 1
ans = ans_d[5] * (ans_d[5] - 1) * (ans_d[3] - 2) // 2 + ans_d[75]
for n1 in ans_d:
	for n2 in ans_d:
		if n1 < n2 and n1 * n2 == 75:
			ans += ans_d[n2] * (ans_d[n1] - 1)
print(ans)


from math import factorial
from itertools import permutations

def eratosthenes(n):
	is_p = [1] * n
	p_list = []
	is_p[0] = 0
	is_p[1] = 0
	for i in range(2, n):
		if is_p[i]:
			p_list.append(i)
			for j in range(i * i, n, i):
				is_p[j] = 0
	return (is_p, p_list)
n = int(input())
np = factorial(n)
lim = 10 ** 2 + 1
(is_p, p_list) = eratosthenes(lim)
ans = []
for (s, t, u) in permutations(p_list, 3):
	num1 = s ** 4 * t ** 4 * u ** 2
	num2 = s ** 14 * t ** 4
	num3 = s ** 24 * t ** 2
	num4 = s ** 74
	for z in [num1, num2, num3, num4]:
		if np % z == 0:
			ans.append(z)
print(len(set(ans)))


from itertools import combinations
from collections import defaultdict
n = int(input())

def sieve(n):
	n += 1
	res = [i for i in range(n)]
	for p in range(2, int(n ** 0.5) + 1):
		if res[p] < p:
			continue
		for q in range(p ** 2, n, p):
			if res[q] == q:
				res[q] = p
	return res
U = 100
min_factor = sieve(U)

def prime_factor(n):
	res = defaultdict(int)
	while 1 < n:
		res[min_factor[n]] += 1
		n //= min_factor[n]
	return res
cnt = defaultdict(int)
for i in range(1, n + 1):
	for (k, v) in list(prime_factor(i).items()):
		cnt[k] += v
facts = list(cnt.keys())
ans = 0
for subset in combinations(facts, 3):
	for i in range(3):
		can_be = 1
		for (j, prim) in enumerate(subset):
			if i == j:
				if cnt[prim] < 2:
					can_be = 0
					break
			elif cnt[prim] < 4:
				can_be = 0
				break
		if can_be:
			ans += 1
for subset in combinations(facts, 2):
	for i in range(2):
		can_be = 1
		for (j, prim) in enumerate(subset):
			if i == j:
				if cnt[prim] < 4:
					can_be = 0
					break
			elif cnt[prim] < 14:
				can_be = 0
				break
		if can_be:
			ans += 1
		can_be2 = 1
		for (j, prim) in enumerate(subset):
			if i == j:
				if cnt[prim] < 2:
					can_be2 = 0
					break
			elif cnt[prim] < 24:
				can_be2 = 0
				break
		if can_be2:
			ans += 1
if 74 <= cnt[2]:
	ans += 1
print(ans)


from collections import defaultdict
import math
n = int(input())

def is_prime(n):
	if n == 1:
		return False
	for k in range(2, int(math.sqrt(n)) + 1):
		if n % k == 0:
			return False
	return True
d = defaultdict(int)
p = []
for i in range(2, n + 1):
	if is_prime(i):
		d[i] = 1
		p.append(i)
		continue
	x = i
	for j in p:
		while x % j == 0:
			x //= j
			d[j] += 1
c = 0
for i in list(d.values()):
	if i >= 74:
		c += 1
ans = c
(c, e) = (0, 0)
for i in list(d.values()):
	if i >= 24:
		c += 1
	if i >= 2:
		e += 1
ans += c * (e - 1)
(c, e) = (0, 0)
for i in list(d.values()):
	if i >= 14:
		c += 1
	if i >= 4:
		e += 1
ans += c * (e - 1)
(c, e) = (0, 0)
for i in list(d.values()):
	if i >= 4:
		c += 1
	if i >= 2:
		e += 1
ans += c * (c - 1) // 2 * (e - 2)
print(ans)


N = int(input())
e = [0 for _ in range(N + 1)]
for i in range(2, N + 1):
	for j in range(2, i + 1):
		while i % j == 0:
			i //= j
			e[j] += 1
c = tuple(filter(lambda x: x > 0, e))
dp = [[0 for _ in range(75 + 1)] for _ in range(len(c) + 1)]
dp[0][1] = 1
i = 1
for cc in c:
	for j in range(1, 75 + 1):
		k = 0
		while j * (k + 1) <= 75 and k <= cc:
			dp[i][j * (k + 1)] += dp[i - 1][j]
			k += 1
	i += 1
print(dp[len(c)][75])


def prime_factorization(x):
	import math
	re = []
	i = 2
	while x != 1:
		if x % i == 0:
			re.append(i)
			x //= i
		else:
			i += 1
			if i > math.sqrt(x):
				re.append(x)
				break
	return re

def solve(N):
	pf = []
	for i in range(1, N + 1):
		pf += prime_factorization(i)
	pf_nums = [0] * (N + 1)
	for p in pf:
		pf_nums[p] += 1

	def num(m):
		return len([i for i in pf_nums if i >= m - 1])
	ans = num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2
	print(ans)

def __starting_point():
	N = int(input())
	solve(N)
__starting_point()


N = int(input())
div_num = [0] * (N + 1)
for i in range(2, N + 1):
	cur = i
	for j in range(2, i + 1):
		while cur % j == 0:
			div_num[j] += 1
			cur = cur // j
MAX_VALUE = 80
dp = [0] * MAX_VALUE
dp[1] = 1
for i in range(2, N + 1):
	for j in range(MAX_VALUE - 1, -1, -1):
		for k in range(1, div_num[i] + 1):
			next_ = j * (k + 1)
			if next_ >= MAX_VALUE:
				break
			dp[next_] += dp[j]
print(dp[75])


import sys
sys.setrecursionlimit(10 ** 8)

def Z():
	return int(input())

def ZZ():
	return [int(_) for _ in input().split()]

def main():
	N = Z()

	def sieve(num):
		isPrime = [True] * (num + 1)
		isPrime[0] = isPrime[1] = False
		for i in range(2, num + 1):
			if i * i > num:
				break
			if not isPrime[i]:
				continue
			for j in range(i, num + 1):
				if i * j > num:
					break
				isPrime[i * j] = False
		return isPrime
	ps = []
	cs = []
	s = sieve(N)
	for i in range(N + 1):
		if s[i]:
			ps.append(i)
	for p in ps:
		(cc, q) = (0, p)
		while N // q > 0:
			cc += N // q
			q *= p
		cs.append(cc)
	ans = set()
	for i in range(len(cs)):
		if cs[i] >= 74:
			ans.add(pow(ps[i], 74))
	for i in range(len(cs)):
		for j in range(len(cs)):
			if i == j:
				continue
			if cs[i] >= 24 and cs[j] >= 2:
				ans.add(pow(ps[i], 24) * pow(ps[j], 2))
			if cs[i] >= 14 and cs[j] >= 4:
				ans.add(pow(ps[i], 14) * pow(ps[j], 4))
	for i in range(len(cs)):
		for j in range(len(cs)):
			for k in range(len(cs)):
				if i == j or j == k or k == i:
					continue
				if cs[i] >= 4 and cs[j] >= 4 and (cs[k] >= 2):
					ans.add(pow(ps[i], 4) * pow(ps[j], 4) * pow(ps[k], 2))
	print(len(ans))
	return

def __starting_point():
	main()
__starting_point()


def make_prime_table(n):
	sieve = list(range(n + 1))
	sieve[0] = -1
	sieve[1] = -1
	for i in range(2, int(n ** 0.5) + 1):
		if sieve[i] != i:
			continue
		for j in range(i * i, n + 1, i):
			if sieve[j] == j:
				sieve[j] = i
	return sieve

def prime_factorize(n):
	result = []
	while n != 1:
		p = prime_table[n]
		c = 0
		while n % p == 0:
			n //= p
			c += 1
		result.append((p, c))
	return result
N = int(input())
prime_table = make_prime_table(100)
d = {}
for i in range(2, N + 1):
	for (p, c) in prime_factorize(i):
		d.setdefault(p, 0)
		d[p] += c
n74 = 0
n24 = 0
n14 = 0
n4 = 0
n2 = 0
for k in d:
	if d[k] >= 74:
		n74 += 1
	if d[k] >= 24:
		n24 += 1
	if d[k] >= 14:
		n14 += 1
	if d[k] >= 4:
		n4 += 1
	if d[k] >= 2:
		n2 += 1
result = 0
result += n4 * (n4 - 1) // 2 * (n2 - 2)
result += n14 * (n4 - 1)
result += n24 * (n2 - 1)
result += n74
print(result)


import copy
N = int(input())
sosu = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97]
soinsu = dict()
for n in range(2, N + 1):
	if n in sosu:
		soinsu[n] = 1
	else:
		x = copy.deepcopy(n)
		i = 0
		while i < len(sosu):
			if x % sosu[i] == 0:
				soinsu[sosu[i]] += 1
				x = x // sosu[i]
			else:
				i += 1
ans = 0
cnt = [0, 0, 0, 0, 0]
tit = [2, 4, 14, 24, 74]
for (_, v) in soinsu.items():
	for i in range(5):
		cnt[i] += 1 if v >= tit[i] else 0
ans += cnt[1] * (cnt[1] - 1) // 2 * (cnt[0] - 2)
ans += cnt[2] * (cnt[1] - 1)
ans += cnt[3] * (cnt[0] - 1)
ans += cnt[4]
print(ans)


n = int(input())
A = [0 for i in range(n + 1)]
for i in range(2, n + 1):
	j = 2
	while i != 1:
		if i % j == 0:
			i = i // j
			A[j] += 1
		else:
			j += 1
B = []
for i in [2, 4, 14, 24, 74]:
	co = 0
	for j in A:
		if j >= i:
			co += 1
	B.append(co)
print((B[0] - 2) * B[1] * (B[1] - 1) // 2 + (B[1] - 1) * B[2] + (B[0] - 1) * B[3] + B[4])


import math
n = int(input())
lis = [0] * n
for i in range(2, n + 1):
	now = i
	for j in range(2, math.ceil(math.sqrt(i)) + 1):
		while now % j == 0:
			now //= j
			lis[j - 1] += 1
	if now != 1:
		lis[now - 1] += 1

def num(l):
	return len(list(filter(lambda x: x >= l - 1, lis)))
print(num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2)


n = int(input())
l = {}
if n <= 9:
	print(0)
else:
	for i in range(2, n + 1):
		x = i
		for j in range(2, i + 1):
			while x % j == 0:
				if j in l:
					l[j] += 1
				else:
					l[j] = 1
				x = x // j
	c = 0
	if l[2] >= 74:
		c += 1
	c3 = 0
	c5 = 0
	c25 = 0
	c15 = 0
	for i in l:
		if l[i] >= 2:
			c3 += 1
			if l[i] >= 4:
				c5 += 1
				if l[i] >= 14:
					c15 += 1
					if l[i] >= 24:
						c25 += 1
	print(c5 * (c5 - 1) * (c3 - 2) // 2 + c25 * (c3 - 1) + c15 * (c5 - 1) + c)


N = int(input())

def factorize(n):
	(i, factors) = (2, [])
	while i * i <= n:
		while n % i == 0:
			n //= i
			factors.append(i)
		i += 1
	if n > 1:
		factors.append(n)
	return factors
e = [0] * (N + 1)
for i in range(1, N + 1):
	for s in factorize(i):
		e[s] += 1

def f(n):
	cnt = 0
	for x in e:
		if x >= n - 1:
			cnt += 1
	return cnt
ans = f(75)
ans += f(25) * (f(3) - 1)
ans += f(15) * (f(5) - 1)
ans += f(5) * (f(5) - 1) * (f(3) - 2) // 2
print(ans)


N = int(input())
p = [0] * (N + 1)

def is_prime(n):
	for i in range(2, n):
		if not n % i:
			return False
	return True

def n(m):
	return sum([True for i in p if i >= m])
l = [i for i in range(2, N + 1) if is_prime(i)]
for i in range(2, N + 1):
	for j in l:
		while not i % j:
			p[j] += 1
			i //= j
print(n(74) + (n(2) - 1) * n(24) + (n(2) - 2) * ((n(4) - 1) * n(4)) // 2 + (n(4) - 1) * n(14))


import sys
primes = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97]
num3 = 0
num5 = 0
num15 = 0
num25 = 0
num75 = 0
n = int(input())
for i in primes:
	tmp = 0
	j = 1
	while n // pow(i, j) > 0:
		tmp += n // pow(i, j)
		j += 1
	if tmp >= 2:
		num3 += 1
	if tmp >= 4:
		num5 += 1
	if tmp >= 14:
		num15 += 1
	if tmp >= 24:
		num25 += 1
	if tmp >= 74:
		num75 += 1
print(num75 + max(0, (num3 - 1) * num25) + max(0, (num3 - 2) * (num5 - 1) * num5 // 2) + max(0, (num5 - 1) * num15))


sosuu = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97]
N = int(input())
L = [0 for i in range(25)]
for i in range(25):
	s = N
	while True:
		if s != 0:
			s = s // sosuu[i]
			L[i] += s
		else:
			break
(a, b, c, d, e) = (0, 0, 0, 0, 0)
for i in range(25):
	if L[i] >= 74:
		a += 1
	if L[i] >= 24:
		b += 1
	if L[i] >= 14:
		c += 1
	if L[i] >= 4:
		d += 1
	if L[i] >= 2:
		e += 1
print(a + b * (e - 1) + c * (d - 1) + d * (d - 1) * (e - 2) // 2)


import bisect, collections, copy, heapq, itertools, math, string, sys
input = lambda : sys.stdin.readline().rstrip()
sys.setrecursionlimit(10 ** 7)
INF = float('inf')

def I():
	return int(input())

def F():
	return float(input())

def SS():
	return input()

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

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

def LF():
	return [float(x) for x in input().split()]

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

def primeFactorization(n):
	ans = []
	temp = n
	while temp % 2 == 0:
		ans.append(2)
		temp //= 2
	for i in range(3, int(n ** 0.5) + 1, 2):
		while temp % i == 0:
			ans.append(i)
			temp //= i
	if temp > 1:
		ans.append(temp)
	return collections.Counter(ans)

def resolve():
	N = I()
	pf_N_fact = collections.Counter()
	for i in range(1, N + 1):
		pf = primeFactorization(i)
		for (k, v) in list(pf.items()):
			pf_N_fact[k] += v
	l = list(pf_N_fact.values())
	l.sort()
	pf_num = len(pf_N_fact)
	ans = 0
	num_2 = pf_num - bisect.bisect_left(l, 2)
	num_4 = pf_num - bisect.bisect_left(l, 4)
	num_14 = pf_num - bisect.bisect_left(l, 14)
	num_24 = pf_num - bisect.bisect_left(l, 24)
	num_74 = pf_num - bisect.bisect_left(l, 74)
	ans += num_4 * (num_4 - 1) // 2 * max(num_2 - 2, 0)
	ans += num_24 * max(num_2 - 1, 0)
	ans += num_14 * max(num_4 - 1, 0)
	ans += num_74
	print(ans)

def __starting_point():
	resolve()
__starting_point()


answer = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 3, 3, 3, 3, 8, 8, 11, 11, 11, 11, 14, 14, 32, 32, 35, 35, 35, 35, 42, 42, 42, 42, 49, 49, 49, 49, 49, 49, 75, 75, 86, 86, 86, 86, 86, 86, 123, 123, 131, 131, 131, 131, 148, 148, 153, 153, 170, 170, 170, 170, 170, 170, 227, 227, 227, 227, 227, 227, 250, 250, 323, 323, 324, 324, 324, 324, 354, 354, 354, 354, 384, 384, 384, 384, 384, 391, 491, 491, 529, 529, 529, 529, 529, 529, 543]
N = int(input())
print(answer[N])


from collections import defaultdict
n = int(input())
d = defaultdict(int)
for i in range(1, n + 1):
	j = 2
	while i > 1:
		if i % j == 0:
			d[j] += 1
			i = i // j
		else:
			j += 1
x = {75: 0, 25: 0, 15: 0, 5: 0, 3: 0}
for y in x:
	for v in d.values():
		if v + 1 >= y:
			x[y] += 1
ans = 0
ans += x[75]
ans += x[15] * (x[5] - 1) if x[5] >= 1 else 0
ans += x[25] * (x[3] - 1) if x[3] >= 1 else 0
ans += x[5] * (x[5] - 1) // 2 * (x[3] - 2) if x[3] >= 2 else 0
print(ans)


N = int(input())
p_dict = {2: 1, 3: 1}
for num in range(4, N + 1):
	is_prime = True
	for (prime, cnt) in p_dict.items():
		if num % prime == 0:
			p_dict[prime] = cnt + 1
			idx = 2
			while num % prime ** idx == 0:
				idx += 1
				p_dict[prime] += 1
			is_prime = False
	if is_prime:
		p_dict[num] = 1

def num(n):
	return len(list(filter(lambda x: x >= n - 1, p_dict.values())))
ans = num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2
print(ans)


n = int(input())
P = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97]
D = dict()
for p in P:
	count = 0
	order = 1
	while p ** order <= n:
		count += n // p ** order
		order += 1
	D[p] = count
List = [0 for i in range(5)]
for p in P:
	if D[p] >= 74:
		List[4] += 1
	elif D[p] >= 24:
		List[3] += 1
	elif D[p] >= 14:
		List[2] += 1
	elif D[p] >= 4:
		List[1] += 1
	elif D[p] >= 2:
		List[0] += 1
for i in range(4):
	List[3 - i] += List[4 - i]
print(List[4] + (List[0] - 1) * List[3] + (List[1] - 1) * List[2] + (List[0] - 2) * List[1] * (List[1] - 1) // 2)


def num(m):
	return len(tuple(filter(lambda x: x >= m - 1, e)))
N = int(input())
e = [0 for _ in range(N + 1)]
for i in range(2, N + 1):
	for j in range(2, i + 1):
		while i % j == 0:
			i //= j
			e[j] += 1
ans = 0
ans += num(75)
ans += num(25) * (num(3) - 1)
ans += num(15) * (num(5) - 1)
ans += num(5) * (num(5) - 1) * (num(3) - 2) // 2
print(ans)


n = int(input())
arr = [0] * (n + 1)
for i in range(2, n + 1):
	tmp = i
	div = 2
	while div <= i:
		if tmp % div == 0:
			arr[div] += 1
			tmp //= div
		else:
			div += 1

def count(n):
	return len([i for i in arr if i >= n])
ans = count(74) + count(24) * (count(2) - 1) + count(14) * (count(4) - 1) + count(4) * (count(4) - 1) * (count(2) - 2) // 2
print(ans)


n = int(input())
d = [0] * 101
for i in range(n + 1):
	i0 = i + 0
	for j in range(2, i0 + 1):
		while i % j == 0:
			d[j] += 1
			i = i // j
d.sort()
d1 = [i for i in d if i >= 2]

def num(m):
	return len(list(filter(lambda x: x >= m - 1, d1)))
print(num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2)


N = int(input())
primes = set(range(2, N + 1))
for i in range(2, int(N ** 0.5 + 1)):
	primes.difference_update(range(i * 2, N + 1, i))
primes = list(primes)
primes.sort()
div = [0] * len(primes)
for i in range(2, N + 1):
	num = i
	for (j, prime) in enumerate(primes):
		cnt = 0
		if num < prime:
			break
		while num % prime == 0:
			cnt += 1
			num //= prime
		div[j] += cnt
(c74, c24, c14, c4, c2) = (0, 0, 0, 0, 0)
for i in div:
	if i >= 74:
		c74 += 1
	if i >= 24:
		c24 += 1
	if i >= 14:
		c14 += 1
	if i >= 4:
		c4 += 1
	if i >= 2:
		c2 += 1
ans = 0
ans += c74
ans += c24 * (c2 - 1)
ans += c14 * (c4 - 1)
ans += c4 * (c4 - 1) // 2 * (c2 - 2)
print(ans)


n = int(input())
p = {}
for i in range(2, n + 1):
	j = i
	for d in range(2, j + 1):
		while j % d == 0:
			p[d] = p.get(d, 0) + 1
			j //= d

def doit(ds, ps):
	if ds == []:
		return 1
	if ps == []:
		return 0
	ret = doit(ds, ps[1:])
	if ps[0] + 1 >= ds[0]:
		ret += doit(ds[1:], ps[1:])
	return ret
ret = 0
for ds in ([3, 5, 5], [5, 3, 5], [5, 5, 3], [5, 15], [15, 5], [3, 25], [25, 3], [75]):
	ret += doit(ds, list(p.values()))
print(ret)


import sys
import math
import collections
import bisect
import copy
sys.setrecursionlimit(10 ** 9)
INF = 10 ** 16
MOD = 10 ** 9 + 7
ni = lambda : int(sys.stdin.readline())
ns = lambda : list(map(int, sys.stdin.readline().split()))
na = lambda : list(map(int, sys.stdin.readline().split()))
na1 = lambda : list([int(x) - 1 for x in sys.stdin.readline().split()])

def main():

	def prime_factorize(n):
		a = []
		while n % 2 == 0:
			a.append(2)
			n //= 2
		f = 3
		while f * f <= n:
			if n % f == 0:
				a.append(f)
				n //= f
			else:
				f += 2
		if n != 1:
			a.append(n)
		return a
	n = ni()
	divisor = [0 for _ in range(101)]
	ans = 0
	for i in range(1, n + 1):
		a = prime_factorize(i)
		for ai in a:
			divisor[ai] += 1
	over75 = 0
	over25 = 0
	over15 = 0
	over5 = 0
	over3 = 0
	for di in divisor:
		tmp = di + 1
		if tmp >= 75:
			over75 += 1
		if tmp >= 25:
			over25 += 1
		if tmp >= 15:
			over15 += 1
		if tmp >= 5:
			over5 += 1
		if tmp >= 3:
			over3 += 1
	ans = over75 + over25 * (over3 - 1) + over15 * (over5 - 1) + over5 * (over5 - 1) // 2 * (over3 - 2)
	print(ans)

def __starting_point():
	main()
__starting_point()


import sys
sr = lambda : sys.stdin.readline().rstrip()
ir = lambda : int(sr())
lr = lambda : list(map(int, sr().split()))
N = ir()
exp = [0] * (N + 1)
for i in range(2, N + 1):
	cur = i
	for p in range(2, i + 1):
		while cur % p == 0:
			exp[p] += 1
			cur //= p

def num(x):
	return len(list(filter(lambda y: y >= x - 1, exp)))
answer = num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2
print(answer)


import sys

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

def prime_fact_factorial(n):
	global e
	e = [0] * (n + 1)
	for i in range(2, n + 1):
		cur = i
		for j in range(2, i + 1):
			while cur % j == 0:
				e[j] += 1
				cur //= j

def num(m):
	return len([x for x in e if x >= m - 1])

def main():
	n = int(input())
	prime_fact_factorial(n)
	print(num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2)
main()


n = int(input())
w = [0 for i in range(101)]
for m in range(2, n + 1):
	tmp = m
	for j in range(2, m + 1):
		while tmp % j == 0:
			w[j] += 1
			tmp //= j

def num(a):
	return len(list(filter(lambda x: x >= a - 1, w)))
print(num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2)


import sys
from collections import defaultdict

def solve():
	input = sys.stdin.readline
	N = int(input())
	primes = defaultdict(int)
	ans = 0
	for i in range(1, N + 1):
		k = i
		for j in range(2, i + 1):
			if j ** 2 > i:
				break
			if k % j == 0:
				while k % j == 0:
					primes[j] += 1
					k //= j
		if k > 1:
			primes[k] += 1
	P = []
	for key in primes:
		P.append(primes[key])
	pn = len(P)
	for i in range(pn):
		if P[i] >= 74:
			ans += 1
		if P[i] >= 24:
			for j in range(pn):
				if P[j] >= 2 and j != i:
					ans += 1
		if P[i] >= 14:
			for j in range(pn):
				if P[j] >= 4 and j != i:
					ans += 1
		if P[i] >= 4:
			for j in range(i + 1, pn):
				if P[j] >= 4:
					for k in range(pn):
						if P[k] >= 2 and k != i and (k != j):
							ans += 1
	print(ans)
	return 0

def __starting_point():
	solve()
__starting_point()


ma = lambda : map(int, input().split())
lma = lambda : list(map(int, input().split()))
tma = lambda : tuple(map(int, input().split()))
ni = lambda : int(input())
yn = lambda fl: print('YES') if fl else print('NO')
import collections
import math
import itertools
import heapq as hq
import sys
n = ni()

def factorize(n):
	b = 2
	fct = [(1, 1)]
	while b * b <= n:
		cnt = 0
		while n % b == 0:
			n //= b
			cnt += 1
		if cnt >= 1:
			fct.append((b, cnt))
		b = b + 1
	if n > 1:
		fct.append((n, 1))
	return fct
co = collections.Counter()
for i in range(2, n + 1):
	fct = factorize(i)
	for (num, cnt) in fct:
		if num > 1:
			co[num] += cnt
f4 = 0
f2 = 0
f14 = 0
f24 = 0
f74 = 0
for cnt in co.values():
	if cnt >= 74:
		f74 += 1
	if cnt >= 24:
		f24 += 1
	if cnt >= 14:
		f14 += 1
	if cnt >= 4:
		f4 += 1
	if cnt >= 2:
		f2 += 1
ans = f74 + f24 * (f2 - 1) + f14 * (f4 - 1) + f4 * (f4 - 1) // 2 * (f2 - 2)
print(ans)


n = int(input())
e = [0] * (n + 1)
for i in range(2, n + 1):
	for j in range(2, i + 1):
		while i % j == 0:
			e[j] += 1
			i //= j

def f(m):
	return len(list(filter(lambda x: x >= m - 1, e)))
c1 = f(75)
c2 = f(25) * (f(3) - 1)
c3 = f(15) * (f(5) - 1)
c4 = f(5) * (f(5) - 1) * (f(3) - 2) // 2
print(c1 + c2 + c3 + c4)


n = int(input())
N = [0] * (n + 1)

def f(n):
	M = []
	while n % 2 == 0:
		n //= 2
		M.append(2)
	i = 3
	while n >= i:
		while n % i == 0:
			n //= i
			M.append(i)
		i += 2
	return M
for i in range(2, n + 1):
	for j in f(i):
		N[j] += 1

def num(m):
	return len(list(filter(lambda x: x >= m - 1, N)))
print(num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2)


print(sorted([391, 543] + [2, 8, 14, 32, 75, 123, 148, 153, 250, 323, 491] * 2 + [1, 3, 11, 35, 42, 131, 324, 354] * 4 + [384] * 5 + [49, 86, 170, 227, 529] * 6 + [0] * 10)[int(input())])


n = int(input())
lis = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47]
li = []
a = 0
b = 0
c = 0
d = 0
e = 0
for i in range(15):
	p = n
	q = 0
	while p > 0:
		q += p // lis[i]
		p = p // lis[i]
	if q >= 74:
		e += 1
	if q >= 24:
		a += 1
	if q >= 14:
		b += 1
	if q >= 4:
		c += 1
	if q >= 2:
		d += 1
ans = a * (d - 1) + b * (c - 1) + c * (c - 1) // 2 * (d - 2) + e
print(ans)


def find_prime(n):
	e = [0] * (n + 1)
	for tmp in range(2, n + 1):
		i = 2
		while tmp != 1:
			if tmp % i == 0:
				tmp //= i
				e[i] += 1
			else:
				i += 1
	return e

def num(i):
	return len(list(filter(lambda x: x >= i, e)))
n = int(input())
e = find_prime(n)
print(num(74) + num(24) * (num(2) - 1) + num(14) * (num(4) - 1) + num(4) * (num(4) - 1) * (num(2) - 2) // 2)


N = int(input())
e = [0] * (N + 1)
for i in range(2, N + 1):
	cur = i
	for j in range(2, i + 1):
		while cur % j == 0 and cur != 1:
			e[j] += 1
			cur //= j

def num(n):
	count = 0
	for i in range(len(e)):
		if e[i] >= n - 1:
			count += 1
	return count
print(num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2)


p = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47]
a = [0 for i in range(len(p))]
n = int(input())
for i in range(n):
	m = i + 1
	for j in range(len(p)):
		while m % p[j] == 0:
			a[j] += 1
			m = m / p[j]
x = 0
y = 0
z = 0
w = 0
u = 0
for i in range(len(a)):
	if a[i] >= 74:
		x += 1
	if a[i] >= 24:
		y += 1
	if a[i] >= 14:
		z += 1
	if a[i] >= 4:
		w += 1
	if a[i] >= 2:
		u += 1
print(int(x + y * (u - 1) + z * (w - 1) + w * (w - 1) / 2 * (u - 2)))


def prime_factorize(n):
	a = []
	while n % 2 == 0:
		a.append(2)
		n //= 2
	f = 3
	while f * f <= n:
		if n % f == 0:
			a.append(f)
			n //= f
		else:
			f += 2
	if n != 1:
		a.append(n)
	return a
n = int(input())
d = {}
for i in range(2, n + 1):
	p = prime_factorize(i)
	for cp in p:
		if cp in d:
			d[cp] += 1
		else:
			d[cp] = 1
cnt = {75: 0, 25: 0, 15: 0, 5: 0, 3: 0}
for i in d:
	for j in cnt:
		if d[i] >= j - 1:
			cnt[j] += 1
ans = cnt[75] + cnt[25] * (cnt[3] - 1) + cnt[15] * (cnt[5] - 1) + cnt[5] * (cnt[5] - 1) // 2 * (cnt[3] - 2)
print(ans)


from sys import stdin
N = int(stdin.readline().rstrip())
A = [0] * 100
for n in range(1, N + 1):
	i = 2
	while n > 1:
		if n % i == 0:
			n //= i
			A[i] += 1
		else:
			i += 1
x = len([x for x in A if x >= 4])
y = len([x for x in A if x >= 2])
z = len([x for x in A if x >= 14])
w = len([x for x in A if x >= 4])
a = len([x for x in A if x >= 24])
b = len([x for x in A if x >= 2])
print(x * (x - 1) // 2 * (y - 2) + z * (w - 1) + a * (b - 1) + len([x for x in A if x >= 74]))


N = int(input())
counter = [0] * (N + 1)
for i in range(2, N + 1):
	cur = i
	for j in range(2, i + 1):
		while cur % j == 0:
			counter[j] += 1
			cur //= j

def num(n):
	return len([m for m in range(2, N + 1) if counter[m] >= n - 1])
print(num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2)


def c(n, P):
	return sum([1 for p in P if p + 1 >= n])
N = int(input())
pN = {}
for i in range(N + 1):
	for j in range(2, i + 1):
		while i % j == 0:
			i //= j
			pN[j] = pN.get(j, 0) + 1
V = pN.values()
ans = c(75, V)
ans += c(25, V) * (c(3, V) - 1)
ans += c(15, V) * (c(5, V) - 1)
ans += c(5, V) * (c(5, V) - 1) * (c(3, V) - 2) // 2
print(ans)


import collections
n = int(input())

def division(n):
	if n < 2:
		return []
	prime_factors = []
	for i in range(2, int(n ** 0.5) + 1):
		while n % i == 0:
			prime_factors.append(i)
			n //= i
	if n > 1:
		prime_factors.append(n)
	return prime_factors
num = []
for i in range(1, n + 1):
	div = division(i)
	num.extend(div)
c = collections.Counter(num)
div_num = 1
(n2, n4, n14, n24, n74) = (0, 0, 0, 0, 0)
for (k, v) in c.items():
	if 2 <= v:
		n2 += 1
	if 4 <= v:
		n4 += 1
	if 14 <= v:
		n14 += 1
	if 24 <= v:
		n24 += 1
	if 74 <= v:
		n74 += 1
ans = n74 + n24 * (n2 - 1) + n14 * (n4 - 1) + n4 * (n4 - 1) * (n2 - 2) // 2
print(ans)


n = int(input())
e = [0] * (n + 1)
for i in range(2, n + 1):
	num = i
	m = 2
	while m * m <= num:
		while num % m == 0:
			e[m] += 1
			num //= m
		m += 1
	if num > 1:
		e[num] += 1
num2 = num4 = num14 = num24 = num74 = 0
for i in range(len(e)):
	if e[i] >= 2:
		num2 += 1
	if e[i] >= 4:
		num4 += 1
	if e[i] >= 14:
		num14 += 1
	if e[i] >= 24:
		num24 += 1
	if e[i] >= 74:
		num74 += 1
ans = num74 + num24 * (num2 - 1) + num14 * (num4 - 1) + num4 * (num4 - 1) * (num2 - 2) // 2
print(ans)


prime = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47]
s = [0 for i in range(15)]
N = int(input())
for i in range(15):
	j = 1
	while N // prime[i] ** j > 0:
		s[i] += N // prime[i] ** j
		j += 1
(o3, o5, o15, o25, o75) = (0, 0, 0, 0, 0)
for item in s:
	if item >= 2:
		o3 += 1
		if item >= 4:
			o5 += 1
			if item >= 14:
				o15 += 1
				if item >= 24:
					o25 += 1
					if item >= 74:
						o75 += 1
ans = [0, 0, 0, 0]
if o75 > 0:
	ans[0] += 1
if o25 > 0:
	ans[1] += o25 * (o3 - 1)
if o15 > 0:
	ans[2] += o15 * (o5 - 1)
if o5 > 1 and o3 > 2:
	ans[3] += o5 * (o5 - 1) // 2 * (o3 - 2)
print(sum(ans))


def main():
	n = int(input())
	exp_num = [0] * (n + 1)
	for i in range(2, n + 1):
		cur = i
		for j in range(2, i + 1):
			while cur % j == 0:
				exp_num[j] += 1
				cur //= j

	def num(m: int) -> int:
		return len(list(filter(lambda x: x > m - 2, exp_num)))
	total = num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) // 2 * (num(3) - 2)
	print(total)
main()


from collections import Counter
from itertools import combinations, permutations

def factor(n):
	res = []
	for i in range(2, int(n ** 0.5) + 1):
		while n % i == 0:
			res.append(i)
			n //= i
	if n > 1:
		return res + [n]
	else:
		return res
N = int(input())
if N < 10:
	print(0)
	return
cnt = Counter()
for i in range(2, N + 1):
	primes = factor(i)
	cnt += Counter(primes)
ans = 0
for (x, y) in combinations(cnt, 2):
	if cnt[x] < 4 or cnt[y] < 4:
		continue
	for z in cnt:
		if z == x or z == y or cnt[z] < 2:
			continue
		ans += 1
for (x, y) in permutations(cnt, 2):
	if cnt[x] >= 14 and cnt[y] >= 4:
		ans += 1
for (x, y) in permutations(cnt, 2):
	if cnt[x] >= 24 and cnt[y] >= 2:
		ans += 1
for x in cnt:
	if cnt[x] >= 74:
		ans += 1
print(ans)


import sys
from collections import defaultdict
sys.setrecursionlimit(10 ** 7)
rl = sys.stdin.readline

def factorization(n):
	arr = []
	temp = n
	for i in range(2, int(-(-n ** 0.5 // 1)) + 1):
		if temp % i == 0:
			cnt = 0
			while temp % i == 0:
				cnt += 1
				temp //= i
			arr.append([i, cnt])
	if temp != 1:
		arr.append([temp, 1])
	if not arr:
		arr.append([n, 1])
	return arr

def solve():
	N = int(rl())
	counter = defaultdict(int)
	for x in range(1, N + 1):
		facts = factorization(x)
		for (fact, exp) in facts:
			counter[fact] += exp
	M = len(list(counter.keys()))
	nums = tuple(counter.values())
	div75 = (1, 3, 5, 15, 25, 75)
	dp = [[0] * 76 for _ in range(M + 1)]
	dp[0][1] = 1
	for i in range(M):
		for div0 in div75:
			for div1 in div75:
				if div0 * div1 <= 75 and div1 <= nums[i] + 1:
					dp[i + 1][div0 * div1] += dp[i][div0]
	print(dp[M][75])

def __starting_point():
	solve()
__starting_point()


from collections import defaultdict
d = defaultdict(int)
N = int(input())
for i in range(1, N + 1):
	K = i
	for j in range(2, N + 1):
		if K >= j:
			while K % j == 0:
				d[j] += 1
				K = K // j
T = defaultdict(int)
for (k, v) in d.items():
	if v >= 2:
		T[2] += 1
	if v >= 4:
		T[4] += 1
	if v >= 14:
		T[14] += 1
	if v >= 24:
		T[24] += 1
	if v >= 74:
		T[74] += 1
ans = 0
ans += T[4] * (T[4] - 1) * (T[2] - 2) // 2
ans += T[14] * (T[4] - 1)
ans += (T[2] - 1) * T[24]
ans += T[74]
print(ans)


n = int(input())
from collections import Counter
c = Counter()
for i in range(1, n + 1):
	for j in range(2, i + 1):
		while i % j == 0:
			c[j] += 1
			i //= j

def num(a):
	ret = 0
	for (key, value) in c.items():
		if value >= a:
			ret += 1
	return ret
ans = num(74) + num(24) * (num(2) - 1) + num(14) * (num(4) - 1) + num(4) * (num(4) - 1) // 2 * (num(2) - 2)
print(ans)


n = int(input())
m = [0] * 101
for i in range(1, n + 1):
	for j in range(2, n + 1):
		while i % j == 0:
			a = i // j
			while (a + 1) * j <= i:
				a += 1
			i = a
			m[j] += 1
counter75 = 0
counter25 = 0
counter15 = 0
counter5 = 0
counter3 = 0
for i in range(101):
	if m[i] >= 74:
		counter75 += 1
	if m[i] >= 24:
		counter25 += 1
	if m[i] >= 14:
		counter15 += 1
	if m[i] >= 4:
		counter5 += 1
	if m[i] >= 2:
		counter3 += 1
a = counter5 * (counter5 - 1) * (counter3 - 2) // 2
while (a + 1) * 2 <= counter5 * (counter5 - 1) * (counter3 - 2):
	a += 1
print(counter75 + counter25 * (counter3 - 1) + counter15 * (counter5 - 1) + a)


import math
n = int(input())
div = [0] * 101
for i in range(2, n + 1):
	j = 2
	t = i
	while i > 1 and j <= t:
		if i % j == 0:
			div[j] += 1
			i //= j
		if i % j != 0:
			j += 1
n2 = 0
n4 = 0
n14 = 0
n24 = 0
n74 = 0
for i in range(n):
	if div[i] >= 2:
		n2 += 1
	if div[i] >= 4:
		n4 += 1
	if div[i] >= 14:
		n14 += 1
	if div[i] >= 24:
		n24 += 1
	if div[i] >= 74:
		n74 += 1
print(n24 * (n2 - 1) + n14 * (n4 - 1) + n4 * (n4 - 1) // 2 * (n2 - 2) + n74)


N = int(input())
T = [1 for k in range(101)]
for M in range(2, N + 1):
	k = 2
	while k * k <= M:
		if M % k == 0:
			M //= k
			T[k] += 1
		else:
			k += 1
	if M > 1:
		T[M] += 1
C = [0 for k in range(101)]
for k in range(101):
	if T[k] >= 3:
		C[3] += 1
	if T[k] >= 5:
		C[5] += 1
	if T[k] >= 15:
		C[15] += 1
	if T[k] >= 25:
		C[25] += 1
	if T[k] >= 75:
		C[75] += 1
print(C[75] + C[25] * (C[3] - 1) + C[15] * (C[5] - 1) + C[5] * (C[5] - 1) * (C[3] - 2) // 2)


n = int(input())
cntDiviser = [0 for _ in range(n + 1)]
for i in range(2, n + 1):
	tmp = i
	for j in range(2, i + 1):
		while tmp % j == 0:
			cntDiviser[j] += 1
			tmp //= j

def num(m):
	return len(list(filter(lambda x: x >= m, cntDiviser)))
print(num(74) + num(24) * (num(2) - 1) + num(14) * (num(4) - 1) + num(4) * (num(4) - 1) * (num(2) - 2) // 2)


n = int(input())
yakusu = [0] * 105
for num in range(1, n + 1):
	for i in range(2, n + 1):
		while num % i == 0:
			yakusu[i] += 1
			num //= i
		if num == 1:
			break
over = [0] * 100
for i in range(1, n + 1):
	if yakusu[i] >= 2:
		over[2] += 1
	if yakusu[i] >= 4:
		over[4] += 1
	if yakusu[i] >= 14:
		over[14] += 1
	if yakusu[i] >= 24:
		over[24] += 1
	if yakusu[i] >= 74:
		over[74] += 1
ans = over[74] + over[14] * (over[4] - 1) + over[24] * (over[2] - 1) + over[4] * (over[4] - 1) * (over[2] - 2) // 2
print(ans)


N = int(input())
pr = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47]
l = [0] * 15
for i in range(1, N + 1):
	for j in range(15):
		while 1:
			if i % pr[j] == 0:
				i //= pr[j]
				l[j] += 1
			else:
				break
(a, b, c, d, e) = (0, 0, 0, 0, 0)
for i in l:
	if i >= 2:
		a += 1
	if i >= 4:
		b += 1
	if i >= 14:
		c += 1
	if i >= 24:
		d += 1
	if i >= 74:
		e += 1
print((a - 2) * b * (b - 1) // 2 + c * (b - 1) + d * (a - 1) + e)


N = int(input())
D = [0] * (N + 1)
for i in range(2, N + 1):
	a = i
	for j in range(2, i + 1):
		while a % j == 0:
			D[j] += 1
			a //= j

def num(x):
	cnt = 0
	for i in D:
		if i >= x - 1:
			cnt += 1
	return cnt
print(num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2)


N = int(input())
primes = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47]
two = sum((p <= N // 2 for p in primes))
four = sum((p <= N // 4 for p in primes)) if N >= 12 else sum([N >= 9, N >= 6])
ft = sum([N >= 91, N >= 60, N >= 30, N >= 16])
tf = sum([N >= 100, N >= 54, N >= 28])
sf = N >= 78
tff = four * (four - 1) * (two - 2) // 2
ttf = tf * (two - 1)
fft = ft * (four - 1)
sfo = sf
print(tff + ttf + fft + sfo)


from sys import stdin
N = int(stdin.readline().rstrip())
fact = [0] * (N + 1)
for i in range(2, N + 1):
	tmp = i
	for j in range(2, i + 1):
		while tmp % j == 0:
			fact[j] += 1
			tmp //= j

def num(m):
	return len([i for i in fact if i >= m - 1])
ans = 0
ans += num(75) + num(25) * (num(3) - 1)
ans += num(15) * (num(5) - 1)
ans += num(5) * (num(5) - 1) * (num(3) - 2) // 2
print(ans)


from collections import Counter
n = int(input())

def factorization(n):
	c = Counter()
	temp = n
	for i in range(2, int(-(-n ** 0.5 // 1)) + 1):
		if temp % i == 0:
			cnt = 0
			while temp % i == 0:
				cnt += 1
				temp //= i
			c[i] = cnt
	if temp != 1:
		c[temp] = 1
	if len(c) == 0:
		c[n] = 1
	c[1] = 0
	return c

def isOk(c):
	ret = 1
	for (_, v) in c.items():
		ret *= v + 1
	return ret
c = Counter([])
for i in range(1, n + 1):
	c += factorization(i)
lc = [[k, v] for (k, v) in c.items()]
ans = 0
f75 = sum([1 for v in c.values() if v >= 74])
ans += f75
f3 = sum([1 for v in c.values() if v >= 2])
f5 = sum([1 for v in c.values() if v >= 4])
f15 = sum([1 for v in c.values() if v >= 14])
f25 = sum([1 for v in c.values() if v >= 24])
ans += f15 * (f5 - 1)
ans += f25 * (f3 - 1)
if f5 >= 2:
	ans += f5 * (f5 - 1) // 2 * (f3 - 2)
print(ans)


N = int(input())
s_list = [[5, 5, 3], [25, 3], [15, 5], [75]]
a = [0 for i in range(N + 1)]
for i in range(2, N + 1):
	for j in range(2, N + 1):
		while i % j == 0:
			a[j] += 1
			i /= j

def div_c(n):
	return len(list(filter(lambda x: x >= n - 1, a)))
ans = 0
for s in s_list:
	i = 0
	c = 1
	for t in s:
		c *= div_c(t) - i
		i += 1
	ans += int(c / (len(s) - len(set(s)) + 1))
print(ans)


n = int(input())
cnt = [0] * (n + 1)
s = set([2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 91, 97])
for k in range(1, n + 1):
	for i in range(2, k + 1):
		if k % i == 0 and i in s:
			m = k
			while m % i == 0:
				cnt[i] += 1
				m //= i
(cnt2, cnt4, cnt14, cnt24, cnt74) = (0, 0, 0, 0, 0)
for i in range(2, n + 1):
	if cnt[i] >= 2:
		cnt2 += 1
	if cnt[i] >= 4:
		cnt4 += 1
	if cnt[i] >= 14:
		cnt14 += 1
	if cnt[i] >= 24:
		cnt24 += 1
	if cnt[i] >= 74:
		cnt74 += 1
ans = cnt74 + cnt14 * (cnt4 - 1) + cnt24 * (cnt2 - 1) + (cnt2 - 2) * cnt4 * (cnt4 - 1) // 2
print(ans)


from collections import Counter

def prime_factorize(n):
	i = 2
	factors = []
	while i * i <= n:
		while n % i == 0:
			n //= i
			factors.append(i)
		i += 1
	if n > 1:
		factors.append(n)
	return Counter(factors)
n = int(input())
c = Counter([])
for i in range(1, n + 1):
	c += prime_factorize(i)
ans = 0
s = set([i for (i, cnt) in c.items() if cnt >= 4])
t = set([i for (i, cnt) in c.items() if cnt >= 2])
ls = len(s)
lt = len(t)
if ls >= 2:
	ans += ls * (ls - 1) // 2 * (lt - 2)
s = set([i for (i, cnt) in c.items() if cnt >= 24])
t = set([i for (i, cnt) in c.items() if cnt >= 2])
ls = len(s)
lt = len(t)
if ls >= 1:
	ans += ls * (lt - 1)
s = set([i for (i, cnt) in c.items() if cnt >= 14])
t = set([i for (i, cnt) in c.items() if cnt >= 4])
ls = len(s)
lt = len(t)
if ls >= 1:
	ans += ls * (lt - 1)
s = set([i for (i, cnt) in c.items() if cnt >= 74])
ls = len(s)
ans += ls
print(ans)


n = int(input())
e = [0] * (n + 1)
for i in range(2, n + 1):
	cur = i
	for j in range(2, i + 1):
		while cur % j == 0:
			e[j] += 1
			cur //= j

def num(m):
	return sum([ei >= m - 1 for ei in e])
print(num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2)


n = int(input())

def factorize(n, factors):
	d = 2
	orig_n = n
	while d * d <= orig_n and n > 1:
		while n % d == 0:
			factors[d] = factors.get(d, 0) + 1
			n //= d
		d += 1
	if n > 1:
		factors[n] = factors.get(n, 0) + 1

def geq(val, factors):
	return len([x for x in factors if factors[x] >= val])
factors = {}
for i in range(1, n + 1):
	factorize(i, factors)
ans = 0
ans += geq(74, factors)
ans += geq(24, factors) * (geq(2, factors) - 1)
ans += geq(14, factors) * (geq(4, factors) - 1)
ans += geq(4, factors) * (geq(4, factors) - 1) // 2 * (geq(2, factors) - 2)
print(ans)


def solve(string):
	n = int(string)
	d = [0] * (n + 1)
	for i in range(2, n + 1):
		t = i
		for j in range(2, i + 1):
			while t % j == 0:
				d[j] += 1
				t //= j

	def f(n):
		return len(list(filter(lambda x: x >= n - 1, d)))
	(f3, f5) = (f(3), f(5))
	return str(f(75) + f(25) * (f3 - 1) + f(15) * (f5 - 1) + f5 * (f5 - 1) // 2 * (f3 - 2))
print(solve(input()))


from collections import defaultdict
import math
N = int(input())
D = defaultdict(int)

def primes(n):
	is_prime = [True] * (n + 1)
	is_prime[0] = False
	is_prime[1] = False
	for i in range(2, int(n ** 0.5) + 1):
		if not is_prime[i]:
			continue
		for j in range(i * 2, n + 1, i):
			is_prime[j] = False
	return [i for i in range(n + 1) if is_prime[i]]

def prime_cnt(p, n):
	cnt = 0
	temp = p
	while temp <= n:
		cnt += n // temp
		temp *= p
	return cnt

def conb(n, r):
	if n <= 0 or n < r:
		return 0
	elif r == 1:
		return n
	else:
		return n * (n - 1) // 2
for p in primes(N):
	D[p] += prime_cnt(p, N)
C = [0] * 5
L = [3, 5, 15, 25, 75]
for i in D.values():
	for j in range(5):
		if i >= L[j] - 1:
			C[j] += 1
ans = 0
ans += conb(C[4], 1)
ans += conb(C[3], 1) * conb(C[0] - 1, 1)
ans += conb(C[2], 1) * conb(C[1] - 1, 1)
ans += conb(C[1], 2) * conb(C[0] - 2, 1)
print(ans)


from collections import defaultdict
N = int(input())
prm = defaultdict(int)
for n in range(2, N + 1):
	for p in range(2, int(n ** 0.5) + 2):
		while n % p == 0:
			prm[p] += 1
			n //= p
		if n == 1:
			break
	else:
		prm[n] += 1
C = [2, 4, 14, 24, 74]
cnt = [0] * 5
for (p, x) in prm.items():
	for (i, c) in enumerate(C):
		if x >= c:
			cnt[i] += 1
(c2, c4, c14, c24, c74) = cnt
ans = c4 * (c4 - 1) // 2 * (c2 - 2) if c2 > 2 else 0
ans += max(0, c24 * (c2 - 1))
ans += max(0, c14 * (c4 - 1))
ans += c74
print(ans)


from collections import Counter
from copy import deepcopy

def prime_factorize(n):
	a = []
	while n % 2 == 0:
		a.append(2)
		n //= 2
	f = 3
	while f * f <= n:
		if n % f == 0:
			a.append(f)
			n //= f
		else:
			f += 2
	if n != 1:
		a.append(n)
	return a
N = int(input())
prime = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97]
dp = [[0] * 26 for _ in range(N)]
if N == 1:
	print(0)
else:
	for i in range(1, N):
		dp[i] = deepcopy(dp[i - 1])
		temp = Counter(prime_factorize(i + 1))
		for x in temp.items():
			if len(prime_factorize(x[0])) == 1:
				dp[i][prime.index(x[0])] += x[1]
		four = 0
		two = 0
		fourteen = 0
		twenty_four = 0
		seventy_four = 0
		for j in range(25):
			if dp[i][j] >= 74:
				seventy_four += 1
				twenty_four += 1
				fourteen += 1
				four += 1
				two += 1
			elif dp[i][j] >= 24:
				twenty_four += 1
				fourteen += 1
				four += 1
				two += 1
			elif dp[i][j] >= 14:
				fourteen += 1
				four += 1
				two += 1
			elif dp[i][j] >= 4:
				four += 1
				two += 1
			elif dp[i][j] >= 2:
				two += 1
		dp[i][25] = four * (four - 1) // 2 * (two - 2) + twenty_four * (two - 1) + fourteen * (four - 1) + seventy_four
	print(dp[N - 1][25])


import math
n = int(input())
p = [0] * 101
dp = [0] * 101
for i in range(2, n + 1):
	for j in range(2, i + 1):
		while i % j == 0:
			i //= j
			p[j] += 1
for i in range(101):
	if p[i] != 0:
		dp[p[i]] += 1
ans = sum(dp[74:]) + sum(dp[24:]) * (sum(dp[2:]) - 1) + sum(dp[14:]) * (sum(dp[4:]) - 1) + sum(dp[4:]) * (sum(dp[4:]) - 1) // 2 * (sum(dp[2:]) - 2)
print(ans)


from collections import defaultdict

def factorize(N):
	p = 2
	while p * p <= N:
		while N % p == 0:
			N //= p
			fact[p] += 1
		p += 1
	if N > 1:
		fact[N] += 1
n = int(input())
fact = defaultdict(int)
for i in range(n):
	factorize(i + 1)
cnt = {2: 0, 4: 0, 14: 0, 24: 0, 74: 0}
for vfact in fact.values():
	for i in cnt:
		cnt[i] += vfact >= i
ans = cnt[4] * (cnt[4] - 1) * (cnt[2] - 2) // 2
ans += cnt[24] * (cnt[2] - 1) + cnt[14] * (cnt[4] - 1) + cnt[74]
print(ans)


def make_prime_table(N):
	sieve = [0] * (N + 1)
	sieve[0] = -1
	sieve[1] = -1
	for i in range(2, N + 1):
		if sieve[i] != 0:
			continue
		sieve[i] = i
		for j in range(i * i, N + 1, i):
			if sieve[j] == 0:
				sieve[j] = i
	return sieve
N = int(input())
prime_table = make_prime_table(100)
d = {}
for i in range(2, N + 1):
	while i != 1:
		d.setdefault(prime_table[i], 0)
		d[prime_table[i]] += 1
		i //= prime_table[i]
n74 = 0
n24 = 0
n14 = 0
n4 = 0
n2 = 0
for k in d:
	if d[k] >= 74:
		n74 += 1
	if d[k] >= 24:
		n24 += 1
	if d[k] >= 14:
		n14 += 1
	if d[k] >= 4:
		n4 += 1
	if d[k] >= 2:
		n2 += 1
result = 0
result += n4 * (n4 - 1) // 2 * (n2 - 2)
result += n14 * (n4 - 1)
result += n24 * (n2 - 1)
result += n74
print(result)


from math import *
from collections import *

def factorize(n):
	b = 2
	fct = []
	while b * b <= n:
		while n % b == 0:
			n //= b
			fct.append(b)
		b += 1
	if n > 1:
		fct.append(n)
	return fct

def fil(num):
	return len([1 for (k, v) in l.items() if v >= num - 1])
l = []
for i in range(2, int(input()) + 1):
	l.extend(factorize(i))
l = Counter(l)
print(fil(75) + fil(25) * (fil(3) - 1) + fil(15) * (fil(5) - 1) + fil(5) * (fil(5) - 1) * (fil(3) - 2) // 2)


import collections
n = int(input())
counts = collections.defaultdict(int)
for x in range(2, n + 1):
	for y in range(2, n + 1):
		while x % y == 0:
			counts[y] += 1
			x //= y

def f(a):
	return sum((1 for b in counts if counts[b] >= a - 1))
answer = f(75) + f(5) * (f(5) - 1) * (f(3) - 2) // 2 + f(15) * (f(5) - 1) + f(25) * (f(3) - 1)
print(answer)


from collections import Counter
from itertools import chain

def prime_set(N):
	if N < 4:
		return ({}, {}, {2}, {2, 3})[N]
	Nsq = int(N ** 0.5 + 0.5) + 1
	primes = {2, 3} | set(chain(range(5, N + 1, 6), range(7, N + 1, 6)))
	for i in range(5, Nsq, 2):
		if i in primes:
			primes -= set(range(i * i, N + 1, i * 2))
	return primes

def prime_factorization(n):
	res = []
	for i in range(2, int(n ** 0.5) + 1):
		if n % i == 0:
			cnt = 0
			while n % i == 0:
				cnt += 1
				n //= i
			res.append((i, cnt))
	if n > 1:
		res.append((n, 1))
	return res
N = int(input())
primes = {p: 0 for p in prime_set(100)}
for i in range(2, N + 1):
	pf = prime_factorization(i)
	for (p, f) in pf:
		primes[p] += f
n2 = n4 = n14 = n24 = n74 = 0
for v in primes.values():
	if v >= 74:
		n74 += 1
	if v >= 24:
		n24 += 1
	if v >= 14:
		n14 += 1
	if v >= 4:
		n4 += 1
	if v >= 2:
		n2 += 1
ans = 0
if n74:
	ans += n74
if n24:
	ans += n24 * (n2 - 1)
if n14:
	ans += n14 * (n4 - 1)
if n4 >= 2 and n2:
	ans += n4 * (n4 - 1) // 2 * (n2 - 2)
print(ans)


n = int(input())
D = [0] * (n + 1)

def check_div_n(div_list, n):
	return len([d for d in div_list if d >= n and d != 0])
for i in range(2, n + 1):
	check_n = i
	for j in range(2, n + 1):
		while check_n % j == 0:
			D[j] += 1
			check_n = check_n // j
ans = check_div_n(D, 74) + (check_div_n(D, 4) - 1) * check_div_n(D, 14) + (check_div_n(D, 2) - 1) * check_div_n(D, 24) + check_div_n(D, 4) * (check_div_n(D, 4) - 1) // 2 * (check_div_n(D, 2) - 2)
print(ans)


import sys
from collections import deque, Counter
from heapq import heappop, heappush
from bisect import bisect_right
from itertools import accumulate
sys.setrecursionlimit(10 ** 6)
INF = 10 ** 12
m = 10 ** 9 + 7

def cal_divisors(N):
	divisors = []
	i = 1
	while i * i <= N:
		if N % i == 0:
			divisors.append(i)
			if i != N // i:
				divisors.append(N // i)
		i += 1
	divisors.sort()
	return divisors

def prime_factorize(N):
	prime_list = []
	while N % 2 == 0:
		prime_list.append(2)
		N //= 2
	f = 3
	while f ** 2 <= N:
		if N % f == 0:
			prime_list.append(f)
			N //= f
		else:
			f += 2
	if N != 1:
		prime_list.append(N)
	return prime_list

def main():
	N = int(input())
	divisors = []
	for i in range(1, N + 1):
		divisors.extend(prime_factorize(i))
	l = Counter(divisors)
	ans = 0
	nums = list(l.values())
	ans += len([*[x for x in nums if x >= 74]])
	ans += len([*[x for x in nums if x >= 14]]) * (len([*[x for x in nums if x >= 4]]) - 1)
	ans += len([*[x for x in nums if x >= 24]]) * (len([*[x for x in nums if x >= 2]]) - 1)
	ans += len([*[x for x in nums if x >= 4]]) * (len([*[x for x in nums if x >= 4]]) - 1) * (len([*[x for x in nums if x >= 2]]) - 2) // 2
	print(ans)

def __starting_point():
	main()
__starting_point()


import sys
from collections import defaultdict
input = sys.stdin.readline

def calc_prime_factors(n, count=False):
	factors = []
	while n % 2 == 0:
		factors.append(2)
		n //= 2
	f = 3
	root_n = int(n ** 0.5) + 1
	while f <= root_n:
		if n % f == 0:
			factors.append(f)
			n //= f
		else:
			f += 2
	if n != 1:
		factors.append(n)
	return factors

def main():
	N = int(input())
	n_factor = defaultdict(int)
	for n in range(1, N + 1):
		factors = calc_prime_factors(n)
		for f in factors:
			n_factor[f] += 1
	n_factor = list(n_factor.values())
	n_factor.sort()
	ans = 0
	(A, B) = (0, 0)
	for n in n_factor:
		if 2 <= n <= 3:
			A += 1
		elif 4 <= n:
			B += 1
	ans += A * B * (B - 1) // 2 + B * (B - 1) * (B - 2) // 6 * 3
	(A, B) = (0, 0)
	for n in n_factor:
		if 2 <= n <= 23:
			A += 1
		elif 24 <= n:
			B += 1
	ans += A * B + B * (B - 1)
	(A, B) = (0, 0)
	for n in n_factor:
		if 4 <= n <= 13:
			A += 1
		elif 14 <= n:
			B += 1
	ans += A * B + B * (B - 1)
	A = 0
	for n in n_factor:
		if 74 <= n:
			A += 1
	ans += A
	print(ans)

def __starting_point():
	main()
__starting_point()


from collections import Counter
n = int(input())

def prime_factorize(n):
	a = []
	while n % 2 == 0:
		a.append(2)
		n //= 2
	f = 3
	while f * f <= n:
		if n % f == 0:
			a.append(f)
			n //= f
		else:
			f += 2
	if n != 1:
		a.append(n)
	return a
li = []
for i in range(1, n + 1):
	li += prime_factorize(i)
C = Counter(li)
(a, b, c, d, e) = (0, 0, 0, 0, 0)
for i in C.values():
	if i >= 74:
		e += 1
	elif i >= 24:
		d += 1
	elif i >= 14:
		c += 1
	elif i >= 4:
		b += 1
	elif i >= 2:
		a += 1
point = 0
point += e
point += (d + e) * (a + b + c) + (d + e) * (d + e - 1)
point += (c + d + e) * b + (c + d + e) * (c + d + e - 1)
point += a * ((b + c + d + e) * (b + c + d + e - 1) // 2) + (b + c + d + e) * ((b + c + d + e - 1) * (b + c + d + e - 2) // 2)
print(point)


import math
n = int(input())
ans = 0
tmp = [0 for i in range(n + 1)]
for i in range(2, n + 1):
	now = i
	for j in range(2, n + 1):
		while now % j == 0:
			tmp[j] += 1
			now //= j

def solve(x):
	tmp1 = len(list(filter(lambda y: y >= x - 1, tmp)))
	return tmp1
print(solve(75) + solve(25) * (solve(3) - 1) + solve(15) * (solve(5) - 1) + solve(5) * (solve(5) - 1) * (solve(3) - 2) // 2)


from collections import defaultdict
n = int(input())
x = defaultdict(int)
for i in range(2, n + 1):
	k = i
	for j in range(2, i + 1):
		while k % j == 0:
			k = k // j
			x[j] += 1
y = defaultdict(int)
for i in x.values():
	for j in [2, 4, 14, 24, 74]:
		if i >= j:
			y[j] += 1
ans = 0
ans += y[4] * max(0, y[4] - 1) * max(0, y[2] - 2) // 2
ans += y[14] * max(0, y[4] - 1)
ans += y[24] * max(0, y[2] - 1)
ans += y[74]
print(ans)


n = int(input())
a = [0] * (n + 1)
for i in range(2, n + 1):
	x = i
	for j in range(2, n + 1):
		while x % j == 0:
			a[j] += 1
			x //= j

def num(s):
	return len(list(filter(lambda x: x >= s - 1, a)))
ans = 0
ans += num(75)
ans += num(15) * (num(5) - 1)
ans += num(25) * (num(3) - 1)
ans += num(5) * (num(5) - 1) * (num(3) - 2) // 2
print(ans)


n = int(input())
div = [0] * (n + 1)
for i in range(2, n + 1):
	j = 2
	while j * j <= i:
		while i % j == 0:
			div[j] += 1
			i //= j
		j += 1
	if i != 1:
		div[i] += 1
i3 = i5 = i15 = i25 = i75 = 0
for (_, v) in enumerate(div):
	if v >= 74:
		i75 += 1
	if v >= 24:
		i25 += 1
	if v >= 14:
		i15 += 1
	if v >= 4:
		i5 += 1
	if v >= 2:
		i3 += 1
ans = i75
ans += i25 * (i3 - 1)
ans += i15 * (i5 - 1)
ans += (i5 - 1) * i5 // 2 * (i3 - 2)
print(ans)


import collections

def fact(N):
	arr = []
	i = 2
	while i * i <= N:
		if N % i == 0:
			while N % i == 0:
				arr.append(i)
				N //= i
		i += 1
	if N > 1:
		arr.append(N)
	return arr
N = int(input())
arr = []
for i in range(1, N + 1):
	arr += fact(i)
arc = collections.Counter(arr)
num74cnt = 0
num24cnt = 0
num14cnt = 0
num4cnt = 0
num2cnt = 0
for val in list(arc.values()):
	if val >= 74:
		num74cnt += 1
	if val >= 24:
		num24cnt += 1
	if val >= 14:
		num14cnt += 1
	if val >= 4:
		num4cnt += 1
	if val >= 2:
		num2cnt += 1
ans = num74cnt
ans += num24cnt * (num2cnt - 1)
ans += num14cnt * (num4cnt - 1)
ans += num4cnt * (num4cnt - 1) // 2 * (num2cnt - 2)
print(ans)


n = int(input())
e = [0 for i in range(n + 1)]
for i in range(2, n + 1):
	for j in range(2, i + 1):
		if i == 1:
			break
		while i % j == 0:
			i //= j
			e[j] += 1

def num(k):
	ret = 0
	for i in range(n):
		if e[i] >= k - 1:
			ret += 1
	return ret
print(num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2)


n = int(input())

def factorization(n):
	arr = []
	temp = n
	for i in range(2, int(-(-n ** 0.5 // 1)) + 1):
		if temp % i == 0:
			cnt = 0
			while temp % i == 0:
				cnt += 1
				temp //= i
			arr.append([i, cnt])
	if temp != 1:
		arr.append([temp, 1])
	if arr == []:
		arr.append([n, 1])
	return arr
from collections import defaultdict
d = defaultdict(int)
for i in range(1, n + 1):
	x = factorization(i)
	for xi in x:
		d[xi[0]] += xi[1]
di = defaultdict(int)
for k in d:
	if d[k] >= 74:
		di[74] += 1
		di[24] += 1
		di[14] += 1
		di[4] += 1
		di[2] += 1
	elif d[k] >= 24:
		di[24] += 1
		di[14] += 1
		di[4] += 1
		di[2] += 1
	elif d[k] >= 14:
		di[14] += 1
		di[4] += 1
		di[2] += 1
	elif d[k] >= 4:
		di[4] += 1
		di[2] += 1
	elif d[k] >= 2:
		di[2] += 1
ans = di[74]
ans += max(0, di[24] * (di[2] - 1))
ans += max(0, di[14] * (di[4] - 1))
ans += max(0, di[4] * (di[4] - 1) // 2 * (di[2] - 2))
print(max(ans, 0))


import math
N = int(input())
pn = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97]
C3 = 0
C5 = 0
C15 = 0
C25 = 0
C75 = 0
for i in pn:
	if math.factorial(N) % pow(i, 2) == 0:
		C3 += 1
	if math.factorial(N) % pow(i, 4) == 0:
		C5 += 1
	if math.factorial(N) % pow(i, 14) == 0:
		C15 += 1
	if math.factorial(N) % pow(i, 24) == 0:
		C25 += 1
	if math.factorial(N) % pow(i, 74) == 0:
		C75 += 1
ans = (C3 - 2) * C5 * (C5 - 1) // 2 + (C5 - 1) * C15 + (C3 - 1) * C25 + C75
print(ans)


from collections import defaultdict
d = defaultdict(int)
N = int(input())
for i in range(2, N + 1):
	for j in range(2, i + 1):
		while i % j == 0:
			d[j] += 1
			i = i // j
		if i == 1:
			break
(c74, c24, c14, c4, c2) = (0, 0, 0, 0, 0)
for v in d.values():
	if v >= 74:
		c74 += 1
	if v >= 24:
		c24 += 1
	if v >= 14:
		c14 += 1
	if v >= 4:
		c4 += 1
	if v >= 2:
		c2 += 1
ans = 0
ans += c74
ans += c24 * (c2 - 1)
ans += c14 * (c4 - 1)
ans += c4 * (c4 - 1) // 2 * (c2 - 2)
print(ans)


n = int(input())
e = [0] * (n + 1)
for i in range(2, n + 1):
	for j in range(2, i + 1):
		while i % j == 0:
			e[j] += 1
			i //= j

def count(m):
	return len(list(filter(lambda x: x >= m - 1, e)))
a = count(75)
b = count(25) * (count(3) - 1)
c = count(15) * (count(5) - 1)
d = count(5) * (count(5) - 1) * (count(3) - 2) // 2
print(a + b + c + d)


def num_div(n):
	p = []
	for i in range(2, int(n ** 0.5) + 1):
		while n % i == 0:
			p.append(i)
			n //= i
	if n > 1:
		p.append(n)
	return p
n = int(input())
x = [0] * (n + 1)
for i in range(1, n + 1):
	for j in num_div(i):
		x[j] += 1
ex2 = len([i for i in x if i > 1])
ex4 = len([i for i in x if i > 3])
ex14 = len([i for i in x if i > 13])
ex24 = len([i for i in x if i > 23])
ex74 = len([i for i in x if i > 73])
print(ex4 * (ex4 - 1) // 2 * (ex2 - 2) + ex24 * (ex2 - 1) + ex14 * (ex4 - 1) + ex74)


N = int(input())
p = [sum((N // i ** k for k in range(1, 8))) for i in range(2, 97 + 1) if all((i % j != 0 for j in range(2, i)))]

def f(m):
	return len([i for i in p if i >= m])
ans = f(74) + f(24) * (f(2) - 1) + f(14) * (f(4) - 1) + f(4) * (f(4) - 1) * (f(2) - 2) // 2
print(ans)


n = int(input())
prime_factor = {1: 1} if n == 1 else {}
for i in range(2, n + 1):
	while i % 2 == 0:
		prime_factor[2] = prime_factor.get(2, 0) + 1
		i //= 2
	f = 3
	while f * f <= i:
		if i % f == 0:
			prime_factor[f] = prime_factor.get(f, 0) + 1
			i //= f
		else:
			f += 2
	if i != 1:
		prime_factor[i] = prime_factor.get(i, 0) + 1
m = len(prime_factor)
prime = list(prime_factor.keys())
dp = [[0] * 76 for _ in range(m + 2)]
dp[0][1] = 1
for i in range(m):
	for j in range(76):
		for k in range(prime_factor[prime[i]] + 1):
			if (v := (j * (k + 1))) < 76:
				dp[i + 1][v] += dp[i][j]
print(dp[m][75])


n = int(input())
l = [0] * 101
i = 2
for i in range(2, n + 1):
	j = 2
	while i >= 2:
		while i % j == 0:
			i = i // j
			l[j] += 1
		j += 1
ans = sum((x >= 74 for x in l))
a = sum((x >= 2 for x in l))
b = sum((x >= 24 for x in l))
ans += b * (a - 1)
a = sum((x >= 4 for x in l))
b = sum((x >= 14 for x in l))
ans += b * (a - 1)
a = sum((x >= 2 for x in l))
b = sum((x >= 4 for x in l))
ans += b * (b - 1) * (a - 2) // 2
print(ans)


import sys
read = sys.stdin.read

def main():

	def factorization(n):
		arr = []
		temp = n
		for i in range(2, int(-(-n ** 0.5 // 1)) + 1):
			if temp % i == 0:
				cnt = 0
				while temp % i == 0:
					cnt += 1
					temp //= i
				arr.append([i, cnt])
		if temp != 1:
			arr.append([temp, 1])
		if not arr:
			arr.append([n, 1])
		return arr
	n = int(input())
	if n == 1:
		print(0)
		return
	ps = [1] * 101
	for i1 in range(2, n + 1):
		i1fac = factorization(i1)
		for face in i1fac:
			ps[face[0]] += face[1]
	o3 = 0
	o5 = 0
	o15 = 0
	o25 = 0
	o75 = 0
	for pse in ps:
		o3 += pse >= 3
		o5 += pse >= 5
		o15 += pse >= 15
		o25 += pse >= 25
		o75 += pse >= 75
	r = o75
	r += o25 * (o3 - 1)
	r += o15 * (o5 - 1)
	if o5 >= 2:
		r += o5 * (o5 - 1) // 2 * (o3 - 2)
	print(r)

def __starting_point():
	main()
__starting_point()


def prime_factorize(N, lis):
	a = []
	n = N
	while n % 2 == 0:
		lis[2] += 1
		n //= 2
	f = 3
	while f * f <= N:
		if n % f == 0:
			lis[f] += 1
			n //= f
		else:
			f += 2
	if n != 1:
		lis[n] += 1
N = int(input())
lis = [0] * 101
for i in range(1, N + 1):
	prime_factorize(i, lis)
d = [0] * 100
for i in lis:
	d[i] += 1
for i in reversed(range(len(d) - 1)):
	d[i] += d[i + 1]
print(d[74] + d[24] * (d[2] - 1) + d[14] * (d[4] - 1) + d[4] * (d[4] - 1) * (d[2] - 2) // 2)


N = int(input())
prime = [2]
for i in range(2, 101):
	for j in range(2, i - 1):
		if i % j == 0:
			break
	else:
		prime.append(i)
factor = [0] * 101
for i in range(1, N + 1):
	for p in prime:
		if i == 1:
			break
		while i % p == 0:
			i /= p
			factor[p] += 1

def num(m):
	return len(list(filter(lambda x: x >= m - 1, factor)))
print(num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2)


N = int(input())
a = [0] * (N + 1)
for i in range(2, N + 1):
	cnt = i
	for j in range(2, i + 1):
		while cnt % j == 0:
			a[j] += 1
			cnt //= j

def num(m):
	ret = 0
	for i in range(2, N + 1):
		if a[i] >= m:
			ret += 1
	return ret
ans = 0
ans += num(74)
ans += num(24) * (num(2) - 1)
ans += num(14) * (num(4) - 1)
ans += num(4) * (num(4) - 1) * (num(2) - 2) // 2
print(ans)


def prime_factorization(n):
	for i in range(2, n + 1):
		num = int(i ** 0.5)
		for prime in range(2, num + 2):
			if i % prime == 0:
				cnt = 0
				while True:
					if i % prime != 0:
						break
					cnt += 1
					i = i // prime
				if rec.get(prime):
					rec[prime] += cnt
				else:
					rec[prime] = cnt
		if i != 1:
			if rec.get(i):
				rec[i] += 1
			else:
				rec[i] = 1
n = int(input())
rec = dict()
prime_factorization(n)
dic = {2: 0, 4: 0, 14: 0, 24: 0, 74: 0}
cnt = 0
for (key, val) in rec.items():
	if val >= 2:
		dic[2] += 1
	if val >= 4:
		dic[4] += 1
	if val >= 14:
		dic[14] += 1
	if val >= 24:
		dic[24] += 1
	if val >= 74:
		dic[74] += 1
for i in [74, 24, 14, 4]:
	temp = dic.get(i)
	if i == 74:
		cnt += temp
	elif i == 24:
		cnt += temp * (dic[2] - 1)
	elif i == 14:
		cnt += temp * (dic[4] - 1)
	else:
		cnt += (dic[2] - 2) * (temp - 1) * temp // 2
print(cnt)


import sys
input = lambda : sys.stdin.readline().rstrip()
n = int(input())

def prime_factorize(n):
	a = []
	while n % 2 == 0:
		a.append(2)
		n //= 2
	f = 3
	while f * f <= n:
		if n % f == 0:
			a.append(f)
			n //= f
		else:
			f += 2
	if n != 1:
		a.append(n)
	return a
from collections import defaultdict
d = defaultdict(int)
for i in range(2, n + 1):
	a = prime_factorize(i)
	for j in a:
		d[j] += 1
cnt_74 = []
cnt_2 = []
cnt_4 = []
cnt_14 = []
cnt_24 = []
for i in d:
	if d[i] >= 74:
		cnt_74.append(i)
	if d[i] >= 2:
		cnt_2.append(i)
	if d[i] >= 4:
		cnt_4.append(i)
	if d[i] >= 14:
		cnt_14.append(i)
	if d[i] >= 24:
		cnt_24.append(i)
ans = 0
ans += len(cnt_74)
for i in cnt_2:
	for j in cnt_24:
		if i != j:
			ans += 1
for i in cnt_4:
	for j in cnt_14:
		if i != j:
			ans += 1
for i in cnt_2:
	for j in range(len(cnt_4)):
		for k in range(j + 1, len(cnt_4)):
			j_ = cnt_4[j]
			k_ = cnt_4[k]
			if i != j_ and j_ != k_ and (k_ != i):
				ans += 1
print(ans)


q = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97]
N = int(input())
p = {}
for i in range(N):
	n = i + 1
	for j in range(25):
		if n == 1 or n < q[j]:
			break
		while n % q[j] == 0:
			p[q[j]] = 1 if q[j] not in p.keys() else p[q[j]] + 1
			n //= q[j]
n = [1, 3, 13, 23, 73]
m = [len([v for v in p.values() if v > k]) for k in n]
print(m[1] * ~-m[1] // 2 * (m[0] - 2) + m[3] * ~-m[0] + m[2] * ~-m[1] + m[4])


import itertools
N = int(input())
e = [0] * (N + 1)
for i in range(2, N + 1):
	cur = i
	for j in range(2, i + 1):
		while cur % j == 0:
			e[j] += 1
			cur = cur // j
ans = 0
for x in e:
	if x >= 74:
		ans += 1
for (x, y) in itertools.combinations(e, 2):
	for (a, b) in [(24, 2), (14, 4), (4, 14), (2, 24)]:
		if x >= a and y >= b:
			ans += 1
for (x, y, z) in itertools.combinations(e, 3):
	for (a, b, c) in [[4, 4, 2], [4, 2, 4], [2, 4, 4]]:
		if x >= a and y >= b and (z >= c):
			ans += 1
print(ans)


def calc(N, p):
	ans = 0
	i = p
	while N >= i:
		ans += N // i
		i *= p
	return ans

def sieve(n):
	is_prime = [True for _ in range(n + 1)]
	is_prime[0] = False
	for i in range(2, n + 1):
		if is_prime[i - 1]:
			j = 2 * i
			while j <= n:
				is_prime[j - 1] = False
				j += i
	table = [i for i in range(1, n + 1) if is_prime[i - 1]]
	return table
from itertools import groupby, accumulate, product, permutations, combinations

def check(value, lis):
	ans = 0
	n = len(lis)
	for perm in permutations(value, n):
		for i in range(n):
			if perm[i] < lis[i]:
				break
		else:
			ans += 1
	return ans

def solve():
	N = int(input())
	table = sieve(N)
	v = []
	for p in table:
		v.append(calc(N, p))
	v.sort(reverse=True)
	ans = 0
	ans += check(v, [74])
	ans += check(v, [24, 2])
	ans += check(v, [14, 4])
	ans += check(v, [4, 4, 2]) // 2
	return ans
print(solve())


n = int(input())
e = [0] * 101
for x in range(2, n + 1):
	d = 2
	while x > 1:
		c = 0
		while x % d == 0:
			x //= d
			c += 1
		e[d] += c
		d += 1

def f(n, e=e):
	return len(tuple(filter(lambda x: x >= n - 1, e)))
ans = f(75) + f(25) * (f(3) - 1) + f(15) * (f(5) - 1) + f(5) * (f(5) - 1) // 2 * (f(3) - 2)
print(ans)


import numpy as np
N = int(input())
dp = [0] * (N + 1)

def factorization(n):
	arr = []
	temp = n
	for i in range(2, int(-(-n ** 0.5 // 1)) + 1):
		if temp % i == 0:
			cnt = 0
			while temp % i == 0:
				cnt += 1
				temp //= i
			arr.append([i, cnt])
	if temp != 1:
		arr.append([temp, 1])
	if arr == []:
		arr.append([n, 1])
	return arr
for i in range(1, N + 1):
	p = factorization(i)
	for (x, y) in p:
		dp[x] += y
nplist = np.array(dp)
a = nplist[nplist >= 2]
b = nplist[nplist >= 4]
c = nplist[nplist >= 14]
d = nplist[nplist >= 24]
e = nplist[nplist >= 74]
f = len(e)
g = len(d) * (len(a) - 1)
h = len(c) * (len(b) - 1)
k = len(b) * (len(b) - 1) * (len(a) - 2) // 2
print(f + g + h + k)


n = int(input())
a = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97]
b = [0] * 25
for i in range(1, n):
	m = i + 1
	for j in a:
		while m % j == 0:
			b[a.index(j)] += 1
			m //= j
sf = tf = ft = f = t = 0
for i in b:
	if i > 73:
		sf += 1
	if i > 23:
		tf += 1
	if i > 13:
		ft += 1
	if i > 3:
		f += 1
	if i > 1:
		t += 1
ans = sf
ans += tf * (t - 1)
ans += ft * (f - 1)
ans += f * (f - 1) * (t - 2) // 2
print(ans)


from collections import defaultdict as ddict
d = ddict(int)
n = int(input())
for i in range(1, n + 1):
	for p in range(2, int(i ** 0.5) + 2):
		while i % p == 0:
			d[p] += 1
			i //= p
	if i > 1:
		d[i] += 1
g = [2, 4, 14, 24, 74]
f = [0] * 5
for x in d.values():
	for i in range(5):
		if x >= g[i]:
			f[i] += 1
ans = f[1] * (f[1] - 1) // 2 * (f[0] - 2) + f[3] * (f[0] - 1) + f[2] * (f[1] - 1) + f[4]
print(ans)


N = int(input())
pf = [0] * (N + 1)
for n in range(2, N + 1):
	cur = n
	for i in range(2, n + 1):
		while cur % i == 0:
			pf[i] += 1
			cur //= i

def num(n):
	return len(list(filter(lambda x: x >= n - 1, pf)))
print(num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2)


n = int(input())
c = 0
r = 0
for i in range(1, 8):
	r += n // 2 ** i
if r >= 74:
	c += 1
d = 2
q = 0
p = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47]
e = 0
f = 0
a = 0
h = 0
for j in range(15):
	q = 0
	for i in range(1, 7):
		q += n // p[j] ** i
	if q >= 24:
		e += 1
		f += 1
		a += 1
		h += 1
	elif q >= 14:
		f += 1
		a += 1
		h += 1
	elif q >= 4:
		h += 1
		a += 1
	elif q >= 2:
		h += 1
c += e * (h - 1) + f * (a - 1) + a * (a - 1) // 2 * (h - 2)
print(c)


n = int(input())
c = [1] * 101
for i in range(2, n + 1):
	for j in range(2, n + 1):
		while i % j == 0:
			i /= j
			c[j] += 1

def N(M):
	return len([0 for x in c if x >= M])
print(N(75) + N(25) * ~-N(3) + N(15) * ~-N(5) + N(5) * ~-N(5) // 2 * ~-~-N(3))


n = int(input())
f = list()
for i in range(1, n + 1):
	b = 2
	while b * b <= i:
		while i % b == 0:
			i //= b
			f.append(b)
		b += 1
	if i > 1:
		f.append(i)
o2 = o3 = o4 = o14 = o24 = o74 = 0
for i in range(2, n + 1):
	d = f.count(i)
	if d >= 2:
		o2 += 1
	if d >= 4:
		o4 += 1
	if d >= 14:
		o14 += 1
	if d >= 24:
		o24 += 1
	if d >= 74:
		o74 += 1
print(o4 * (o4 - 1) // 2 * (o2 - 2) + o14 * (o4 - 1) + o24 * (o2 - 1) + o74)


def factorization(n):
	arr = []
	temp = n
	for i in range(2, int(-(-n ** 0.5 // 1)) + 1):
		if temp % i == 0:
			cnt = 0
			while temp % i == 0:
				cnt += 1
				temp //= i
			arr.append([i, cnt])
	if temp != 1:
		arr.append([temp, 1])
	if arr == []:
		arr.append([n, 1])
	return arr
N = int(input())
prime = dict()
for i in range(2, N + 1):
	prime_i = factorization(i)
	for (p, num) in prime_i:
		if p in prime:
			prime[p] += num
		else:
			prime[p] = num
divisor_75 = 0
divisor_25 = 0
divisor_15 = 0
divisor_5 = 0
divisor_3 = 0
for v in prime.values():
	if v >= 74:
		divisor_75 += 1
	if v >= 24:
		divisor_25 += 1
	if v >= 14:
		divisor_15 += 1
	if v >= 4:
		divisor_5 += 1
	if v >= 2:
		divisor_3 += 1
ans = 0
ans += divisor_75
ans = max(ans, ans + divisor_25 * (divisor_3 - 1))
ans = max(ans, ans + divisor_15 * (divisor_5 - 1))
ans = max(ans, ans + divisor_5 * (divisor_5 - 1) // 2 * (divisor_3 - 2))
print(ans)


from collections import defaultdict

def main():
	n = int(input())
	fact = defaultdict(int)
	for i in range(2, n + 1):
		j = i
		while j % 2 == 0:
			j //= 2
			fact[2] += 1
		k = 3
		while k * k <= j:
			if j % k:
				k += 2
			else:
				j //= k
				fact[k] += 1
		if j != 1:
			fact[j] += 1
	fact = list(fact.items())
	length = len(fact)
	ans = 0
	for i in range(length):
		if fact[i][1] >= 74:
			ans += 1
	product = set()
	for (small_p, large_p) in [[2, 24], [4, 14]]:
		for i in range(length):
			for j in range(length):
				if i == j:
					continue
				now = pow(fact[i][0], large_p) * pow(fact[j][0], small_p)
				if fact[i][1] >= large_p and fact[j][1] >= small_p and (now not in product):
					ans += 1
					product.add(now)
	for i in range(length):
		for j in range(length):
			for k in range(length):
				if i == j or j == k or i == k:
					continue
				now = pow(fact[i][0], 4) * pow(fact[j][0], 4) * pow(fact[k][0], 2)
				if fact[i][1] >= 4 and fact[j][1] >= 4 and (fact[k][1] >= 2) and (now not in product):
					ans += 1
					product.add(now)
	print(ans)

def __starting_point():
	main()
__starting_point()


def factorization(n):
	arr = []
	temp = n
	for i in range(2, int(-(-n ** 0.5 // 1)) + 1):
		if temp % i == 0:
			cnt = 0
			while temp % i == 0:
				cnt += 1
				temp //= i
			arr.append([i, cnt])
	if temp != 1:
		arr.append([temp, 1])
	if arr == []:
		arr.append([n, 1])
	return arr
n = int(input())
alist = [0] * 101
for i in range(2, n + 1):
	for j in factorization(i):
		alist[j[0]] += j[1]
if n == 1:
	print(0)
else:
	ans = 0
	for i in range(1, 100):
		if alist[i] >= 74:
			ans += 1
		if alist[i] >= 24:
			for j in range(1, 100):
				if i != j and alist[j] >= 2:
					ans += 1
		if alist[i] >= 14:
			for j in range(1, 100):
				if i != j and alist[j] >= 4:
					ans += 1
		if alist[i] >= 2:
			for j in range(1, 100):
				for k in range(j + 1, 100):
					if i != j and k != i and (alist[j] >= 4) and (alist[k] >= 4):
						ans += 1
	print(ans)


class Prime:
	seed_primes = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97]

	def is_prime(self, n):
		is_prime_common = self.is_prime_common(n)
		if is_prime_common is not None:
			return is_prime_common
		if n < 2000000:
			return self.is_prime_brute_force(n)
		else:
			return self.is_prime_miller_rabin(n)

	def is_prime_common(self, n):
		if n == 1:
			return False
		if n in Prime.seed_primes:
			return True
		if any([n % x == 0 for x in self.seed_primes]):
			return False

	def is_prime_brute_force(self, n):
		for k in range(2, int(math.sqrt(n)) + 1):
			if n % k == 0:
				return False
		return True

	def is_prime_miller_rabin(self, n):
		d = n - 1
		while d & 1 == 0:
			d >>= 1
		witnesses = self.get_witnesses(n)
		for w in witnesses:
			y = pow(w, d, n)
			while d != n - 1 and y != 1 and (y != n - 1):
				y = y * y % n
				d <<= 1
			if y != n - 1 and d & 1 == 0:
				return False
		return True

	def get_witnesses(self, num):

		def _get_range(num):
			if num < 2047:
				return 1
			if num < 1373653:
				return 2
			if num < 25326001:
				return 3
			if num < 3215031751:
				return 4
			if num < 2152302898747:
				return 5
			if num < 3474749660383:
				return 6
			if num < 341550071728321:
				return 7
			if num < 3825123056546413051:
				return 9
			return 12
		return self.seed_primes[:_get_range(num)]

	def gcd(self, a, b):
		if a < b:
			return self.gcd(b, a)
		if b == 0:
			return a
		while b:
			(a, b) = (b, a % b)
		return a

	@staticmethod
	def f(x, n, seed):
		p = Prime.seed_primes[seed % len(Prime.seed_primes)]
		return (p * x + seed) % n

	def find_factor(self, n, seed=1):
		if self.is_prime(n):
			return n
		(x, y, d) = (2, 2, 1)
		count = 0
		while d == 1:
			count += 1
			x = self.f(x, n, seed)
			y = self.f(self.f(y, n, seed), n, seed)
			d = self.gcd(abs(x - y), n)
		if d == n:
			return self.find_factor(n, seed + 1)
		return self.find_factor(d)

	def find_factors(self, n):
		primes = {}
		if self.is_prime(n):
			primes[n] = 1
			return primes
		while n > 1:
			factor = self.find_factor(n)
			primes.setdefault(factor, 0)
			primes[factor] += 1
			n //= factor
		return primes
import collections
N = int(input())
c = collections.defaultdict(int)
for i in range(1, N + 1):
	factors = Prime().find_factors(i)
	for (k, v) in list(factors.items()):
		c[k] += v
d = list(c.values())
n75 = sum((i >= 74 for i in d))
n25 = sum((i >= 24 for i in d))
n15 = sum((i >= 14 for i in d))
n5 = sum((i >= 4 for i in d))
n3 = sum((i >= 2 for i in d))
ans = n5 * (n5 - 1) * (n3 - 2) // 2
ans += n25 * (n3 - 1)
ans += n15 * (n5 - 1)
ans += n75
print(ans)


N = int(input())
pdic = {2: 0}
for i in range(3, 50, 2):
	for j in pdic.keys():
		if i % j == 0:
			break
	else:
		pdic[i] = 0
for i in range(2, N + 1):
	for p in pdic.keys():
		while i % p == 0:
			pdic[p] += 1
			i //= p
ge = {i: sum((x >= i - 1 for x in pdic.values())) for i in (3, 5, 15, 25, 75)}
if ge[5] < 2 and ge[3] < 3:
	print(0)
else:
	print(ge[5] * (ge[5] - 1) // 2 * (ge[3] - 2) + ge[25] * (ge[3] - 1) + ge[15] * (ge[5] - 1) + ge[75])


N = int(input())
p = [1] * (N + 1)
for i in range(2, N + 1):
	j = 2
	while i >= j:
		if i % j == 0:
			p[j] += 1
			i //= j
		else:
			j += 1
	if i > 1:
		p[i] += 1
p.sort(reverse=True)

def num(x):
	i = 0
	while p[i] >= x:
		i += 1
	return i
print(num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2)


N = int(input())
pf = [0] * (N + 1)
for i in range(2, N + 1):
	cur = i
	for j in range(2, i + 1):
		while cur % j == 0:
			pf[j] += 1
			cur = int(cur // j)

def count(n):
	f = filter(lambda x: x >= n - 1, pf)
	return len(list(f))
ans = count(75)
ans += count(25) * (count(3) - 1)
ans += count(15) * (count(5) - 1)
ans += count(5) * (count(5) - 1) * (count(3) - 2) // 2
print(ans)


n = int(input())
l_prm = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47]
l_prm = [i for i in l_prm if i <= n / 2]
l_new = []
for i in l_prm:
	a = n
	counter = 0
	b = a
	c = 1
	while b != 0:
		b = a // i ** c
		counter += b
		c += 1
	l_new.append(counter)
ans = 0

def num(j, lst):
	return len([i for i in lst if i >= j])
ans += num(4, l_new) * (num(4, l_new) - 1) / 2 * (num(2, l_new) - 2)
ans += num(14, l_new) * (num(4, l_new) - 1)
ans += num(24, l_new) * (num(2, l_new) - 1)
ans += num(74, l_new)
print(int(ans))


n = int(input())
prime_1 = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47]
prime_2 = [4, 9, 25, 49]
prime_3 = [8, 27]
prime_4 = [16, 81]
dp = [0] * 15
for i in range(15):
	dp[i] += n // prime_1[i]
for j in range(4):
	dp[j] += n // prime_2[j]
for k in range(2):
	dp[k] += n // prime_3[k]
for l in range(2):
	dp[l] += n // prime_4[l]
dp[0] += n // 32
dp[0] += n // 64
n2 = sum((x > 1 for x in dp))
n4 = sum((x > 3 for x in dp))
n14 = sum((x > 13 for x in dp))
n24 = sum((x > 23 for x in dp))
n74 = sum((x > 73 for x in dp))
p553 = (n2 - n4) * (n4 * (n4 - 1) // 2) + n4 * (n4 - 1) * (n4 - 2) // 2
p144 = (n4 - n14) * n14 + n14 * (n14 - 1)
p242 = (n2 - n24) * n24 + n24 * (n24 - 1)
p750 = n74
print(p553 + p144 + p242 + p750)


from collections import defaultdict
import math

def main():

	def factorization(num):
		nonlocal d
		if num in primes:
			d[num] += 1
			return
		for prime in primes:
			if num % prime == 0:
				count = 0
				while num % prime == 0:
					count += 1
					num //= prime
				d[prime] += count

	def generate_primes(num):
		if num == 1:
			return []
		primes = list(range(2, num + 1))
		(i, p) = (0, 1)
		while p <= math.sqrt(num):
			if primes[i] != 0:
				p = primes[i]
				primes = [prime if prime % p != 0 or prime == p else 0 for prime in primes]
			i += 1
		return set((p for p in primes if p != 0))
	n = int(input())
	d = defaultdict(lambda : 1)
	primes = generate_primes(100)
	for i in range(1, n + 1):
		factorization(i)
	c = [0] * 6
	for v in list(d.values()):
		if v >= 3:
			c[0] += 1
		if v >= 75:
			c[5] -= 1
		elif v >= 25:
			c[4] -= 1
		elif v >= 15:
			c[3] -= 1
		elif v >= 5:
			c[2] -= 1
		elif v >= 3:
			c[1] -= 1
	s = 0
	for i in range(6):
		s += c[i]
		c[i] = s
	print(c[1] * (c[1] - 1) * (c[0] - 2) // 2 + c[3] * (c[0] - 1) + c[2] * (c[1] - 1) + c[4])

def __starting_point():
	main()
__starting_point()


from collections import Counter
N = int(input())
l = []
for i in range(1, N + 1):
	while i % 2 == 0:
		l.append(2)
		i //= 2
	f = 3
	while f * f <= i:
		if i % f == 0:
			l.append(f)
			i //= f
		else:
			f += 2
	if i != 1:
		l.append(i)
c = Counter(l)
m = c.most_common()
(c_75, c_25, c_15, c_5, c_3) = (0, 0, 0, 0, 0)
for a in m:
	if a[1] >= 74:
		c_75 += 1
	if a[1] >= 24:
		c_25 += 1
	if a[1] >= 14:
		c_15 += 1
	if a[1] >= 4:
		c_5 += 1
	if a[1] >= 2:
		c_3 += 1
ans = c_75
ans += c_25 * (c_3 - 1)
ans += c_15 * (c_5 - 1)
ans += c_5 * (c_5 - 1) // 2 * (c_3 - 2)
print(ans)


n = int(input())
prime = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47]

def yakusuu(n, p):
	res = 0
	while n > 0:
		n //= p
		res += n
	return res
l2 = 0
l4 = 0
l14 = 0
l24 = 0
l74 = 0
for p in prime:
	y = yakusuu(n, p)
	if y >= 2:
		l2 += 1
	if y >= 4:
		l4 += 1
	if y >= 14:
		l14 += 1
	if y >= 24:
		l24 += 1
	if y >= 74:
		l74 += 1
print(l4 * (l4 - 1) * (l2 - 2) // 2 + l14 * (l4 - 1) + l24 * (l2 - 1) + l74)


def fact(A):
	c0 = A
	r = 2
	lis = []
	count = 1
	while A != 1:
		if A % r == 0:
			A = A // r
			lis.append(r)
			r = 2
		else:
			r += 1
		if r > int(pow(c0, 0.5)) + 1:
			lis.append(A)
			break
	return lis
n = int(input())
lis = []
for i in range(2, n + 1):
	lis.extend(fact(i))
lis = sorted(lis)
L = set(lis)
import collections
c = collections.Counter(lis)
x = [0, 0, 0, 0, 0]
for R in L:
	if c[R] >= 2:
		x[0] += 1
	if c[R] >= 4:
		x[1] += 1
	if c[R] >= 14:
		x[2] += 1
	if c[R] >= 24:
		x[3] += 1
	if c[R] >= 74:
		x[4] += 1
ans = max((x[0] - 2) * (x[1] - 1) * x[1] // 2, 0) + max((x[1] - 1) * x[2], 0) + max((x[0] - 1) * x[3], 0) + x[4]
print(ans)


from collections import Counter, defaultdict
N = int(input())

def primeFactorization(N):
	primes = Counter()
	R = int(N ** 0.5) + 1
	for num in range(2, R):
		while N % num == 0:
			N //= num
			primes[num] += 1
	if N > 1:
		primes[N] = 1
	return primes
primes = Counter()
for i in range(1, N + 1):
	primes += primeFactorization(i)
cnt = defaultdict(int)
for c in list(primes.values()):
	c += 1
	for d in (3, 5, 15, 25, 75):
		if c >= d:
			cnt[d] += 1
ans = 0
ans += cnt[5] * (cnt[5] - 1) * (cnt[3] - 2) // 2
ans += cnt[25] * (cnt[3] - 1)
ans += cnt[15] * (cnt[5] - 1)
ans += cnt[75]
print(ans)


n = int(input())
exponents = [0] * (n + 1)
for i in range(2, n + 1):
	x = i
	for j in range(2, i + 1):
		while x % j == 0:
			exponents[j] += 1
			x //= j

def f(x):
	return sum((exponent >= x - 1 for exponent in exponents))
ans = 0
ans += f(75)
ans += f(25) * (f(3) - 1)
ans += f(15) * (f(5) - 1)
ans += f(5) * (f(5) - 1) // 2 * (f(3) - 2)
print(ans)


from collections import *

def cont(n):
	res = 0
	n -= 1
	for i in c:
		if i >= n:
			res += 1
	return res

def fact_p(n):
	m = n
	i = 2
	a = []
	while n > 1:
		if i > m ** 0.5:
			a += [n]
			break
		if n % i == 0:
			n //= i
			a += [i]
		else:
			i += 1
	return a
n = int(input())
a = []
for i in range(1, n + 1):
	a += fact_p(i)
c = list(Counter(a).values())
print(cont(75) + cont(25) * (cont(3) - 1) + cont(15) * (cont(5) - 1) + cont(5) * (cont(5) - 1) * (cont(3) - 2) // 2)


import sys
sys.setrecursionlimit(10 ** 7)
input = sys.stdin.readline
f_inf = float('inf')
mod = 10 ** 9 + 7

def is_prime(n):
	if n == 1:
		return False
	for k in range(2, int(pow(n, 0.5)) + 1):
		if n % k == 0:
			return False
	return True

def resolve():
	n = int(input())
	primes = []
	for i in range(1, n + 1):
		if is_prime(i):
			primes.append(i)
	fact = []
	for prime in primes:
		ex = 0
		p = prime
		while n // p:
			ex += n // p
			p *= prime
		fact.append(ex)
	cnt_74 = cnt_24 = cnt_14 = cnt_4 = cnt_2 = 0
	for i in fact:
		if i >= 74:
			cnt_74 += 1
		if i >= 24:
			cnt_24 += 1
		if i >= 14:
			cnt_14 += 1
		if i >= 4:
			cnt_4 += 1
		if i >= 2:
			cnt_2 += 1
	res1 = max(0, cnt_24 * (cnt_2 - 1))
	res2 = cnt_4 * (cnt_4 - 1) // 2 * max(0, cnt_2 - 2)
	res3 = max(0, cnt_14 * (cnt_4 - 1))
	print(cnt_74 + res1 + res2 + res3)

def __starting_point():
	resolve()
__starting_point()


from collections import defaultdict
n = int(input())
d = defaultdict(int)

def prime_factorize(n):
	a = []
	while n % 2 == 0:
		a.append(2)
		n //= 2
	f = 3
	while f * f <= n:
		if n % f == 0:
			a.append(f)
			n //= f
		else:
			f += 2
	if n != 1:
		a.append(n)
	return a
for i in range(1, n + 1):
	for x in prime_factorize(i):
		d[x] += 1
e = defaultdict(int)
l = [2, 4, 14, 24, 74]
for (k, v) in d.items():
	for x in l:
		if v >= x:
			e[x] += 1
ans = 0
ans += e[74]
ans += e[24] * (e[2] - 1)
ans += e[14] * (e[4] - 1)
ans += e[4] * (e[4] - 1) // 2 * (e[2] - e[4]) + e[4] * (e[4] - 1) * (e[4] - 2) // 2
print(ans)


n = int(input())
prime = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47]
elecnt = [0] * len(prime)
for i in range(len(prime)):
	c = 1
	while n > prime[i] ** c:
		elecnt[i] += n // prime[i] ** c
		c += 1
above74 = sum((1 for i in elecnt if i >= 74))
above24 = sum((1 for i in elecnt if i >= 24))
above14 = sum((1 for i in elecnt if i >= 14))
above4 = sum((1 for i in elecnt if i >= 4))
above2 = sum((1 for i in elecnt if i >= 2))
print(above74 + above24 * (above2 - 1) + above14 * (above4 - 1) + above4 * (above4 - 1) * (above2 - 2) // 2)


primes = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47]
c = {3: 0, 5: 0, 15: 0, 25: 0, 75: 0}
n = int(input())
for p in primes:
	r = n // p
	a = 0
	while r > 0:
		a += r
		r //= p
	for x in c.keys():
		if x - 1 <= a:
			c[x] += 1
print(c[75] + c[25] * (c[3] - 1) + c[15] * (c[5] - 1) + c[5] * (c[5] - 1) * (c[3] - 2) // 2)


from collections import Counter

def prime_factorize(n):
	i = 2
	factors = []
	while i * i <= n:
		while n % i == 0:
			n //= i
			factors.append(i)
		i += 1
	if n > 1:
		factors.append(n)
	return Counter(factors)
n = int(input())
c = Counter([])
for i in range(1, n + 1):
	c += prime_factorize(i)

def f(x):
	return len([i for (i, cnt) in c.items() if cnt >= x - 1])
ans = 0
ans += f(5) * (f(5) - 1) // 2 * (f(3) - 2)
ans += f(5 * 5) * (f(3) - 1)
ans += f(3 * 5) * (f(5) - 1)
ans += f(3 * 5 * 5)
print(ans)


N = int(input())
factor = [0 for _ in range(N + 1)]
for i in range(2, N + 1):
	n = i
	for j in range(2, i + 1):
		while n % j == 0:
			factor[j] += 1
			n //= j

def num(m):
	return len(list(filter(lambda x: x >= m - 1, factor)))
ans = num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2
print(ans)


import sys
readline = sys.stdin.readline
N = int(readline())
e = [0] * (N + 1)
for i in range(2, N + 1):
	cur = i
	for j in range(2, i + 1):
		while cur % j == 0:
			e[j] += 1
			cur //= j

def num(m):
	return len([1 for x in e if x >= m - 1])

def main():
	print(num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2)
main()


c = [0] * 101
for i in range(1, int(input()) + 1):
	for j in range(2, i + 1):
		while i % j == 0:
			c[j] += 1
			i //= j

def f(n):
	return sum((i > n - 2 for i in c))
print(f(75) + f(25) * (f(3) - 1) + f(15) * (f(5) - 1) + f(5) * (f(5) - 1) * (f(3) - 2) // 2)


from collections import Counter
N = int(input())
p = []
dp = [[0] * 100 for _ in range(100)]
dp[0][1] = 1
for i in range(2, N + 1):
	ti = i
	for j in range(2, i + 1):
		while ti % j == 0:
			p.append(j)
			ti //= j
cnt = Counter(p)
ans = 0
for (i, v) in enumerate(cnt.values()):
	for j in range(100):
		for k in range(1, v + 2):
			dp[i + 1][min(76, j * k)] += dp[i][j]
	ans = dp[i + 1][75]
print(ans)


n = int(input())
if n < 10:
	print(0)
	return
prime = [2, 3]
for i in range(5, n + 1, 2):
	for p in prime:
		if i % p == 0:
			break
	else:
		prime.append(i)
num = []
for p in prime:
	cnt = 1
	now = p
	while now <= n:
		cnt += n // now
		now *= p
	num.append(cnt)
more3 = [i for i in num if i >= 3]
more5 = [i for i in more3 if i >= 5]
more15 = [i for i in more5 if i >= 15]
more25 = [i for i in more15 if i >= 25]
more75 = [i for i in more25 if i >= 75]
more3 = len(more3)
more5 = len(more5)
more15 = len(more15)
more25 = len(more25)
more75 = len(more75)
print(more25 * (more3 - 1) + more15 * (more5 - 1) + more5 * (more5 - 1) * (more3 - 2) // 2 + more75)


import sys
import math
import itertools

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

def factorization(n):
	arr = []
	temp = n
	for i in range(2, int(-(-n ** 0.5 // 1)) + 1):
		if temp % i == 0:
			cnt = 0
			while temp % i == 0:
				cnt += 1
				temp //= i
				arr.append(i)
	if temp != 1:
		arr.append(temp)
	if arr == []:
		arr.append(n)
	return arr

def main():
	N = int(input())
	P = [0] * (N + 1)
	for i in range(1, N + 1):
		arr = factorization(i)
		for s in arr:
			P[s] += 1
	ans = 0
	PN = []
	for j in P:
		if j != 0:
			PN.append(j)
	ans = 0
	count = 0
	for i in PN:
		if i >= 74:
			count += 1
	ans += count
	count = 0
	sub1 = 0
	sub2 = 0
	for i in PN:
		if i >= 24:
			sub1 += 1
		if i >= 2:
			sub2 += 1
	ans += sub1 * (sub2 - 1)
	sub1 = 0
	sub2 = 0
	for i in PN:
		if i >= 14:
			sub1 += 1
		if i >= 4:
			sub2 += 1
	ans += sub1 * (sub2 - 1)
	sub1 = 0
	sub2 = 0
	for i in PN:
		if i >= 4:
			sub1 += 1
		if i >= 2:
			sub2 += 1
	ans += sub1 * (sub1 - 1) * (sub2 - 2) // 2
	print(ans)

def __starting_point():
	main()
__starting_point()


N = int(input())
d = {}
for i in range(2, N + 1):
	m = i
	for j in range(2, i + 1):
		if m == 1:
			break
		while m % j == 0:
			if j in d:
				d[j] = d[j] + 1
			else:
				d[j] = 1
			m = m / j
l = [3, 5, 15, 25, 75]
e = {}
for i in l:
	e[i] = 0
for i in d:
	for j in l:
		if d[i] > j - 2:
			e[j] += 1
ans = 0
if e[5] > 1 and e[3] > 2:
	ans = int(e[5] * (e[5] - 1) / 2 * (e[3] - 2))
if e[3] > 1 and e[25] > 0:
	ans += e[25] * (e[3] - 1)
if e[5] > 1 and e[15] > 0:
	ans += e[15] * (e[5] - 1)
if e[75] > 0:
	ans += e[75]
print(ans)


def prime_factorization(x):
	import math
	re = []
	i = 2
	while x != 1:
		if x % i == 0:
			re.append(i)
			x //= i
		else:
			i += 1
			if i > math.sqrt(x):
				re.append(x)
				break
	return re

def cmb(n, r):
	import math
	if n < r:
		return 0
	return math.factorial(n) // (math.factorial(n - r) * math.factorial(r))

def solve(N):
	pf = []
	for i in range(1, N + 1):
		pf += prime_factorization(i)
	pf_num = {}
	for p in pf:
		pf_num.setdefault(p, 0)
		pf_num[p] += 1
	over2 = 0
	over4 = 0
	over14 = 0
	over24 = 0
	over74 = 0
	for v in list(pf_num.values()):
		if 74 <= v:
			over74 += 1
		if 24 <= v:
			over24 += 1
		if 14 <= v:
			over14 += 1
		if 4 <= v:
			over4 += 1
		if 2 <= v:
			over2 += 1
	ans = 0
	ans += (over2 - over4) * cmb(over4, 2)
	ans += cmb(over4, 3) * 3
	ans += (over4 - over14) * over14
	ans += cmb(over14, 2) * 2
	ans += (over2 - over24) * over24
	ans += cmb(over24, 2) * 2
	ans += over74
	print(ans)

def __starting_point():
	N = int(input())
	solve(N)
__starting_point()


P = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97]
S = [0] * 25
N = int(input())
for i in range(2, N + 1):
	num = i
	j = 0
	while num > 1:
		if num % P[j] == 0:
			num //= P[j]
			S[j] += 1
		else:
			j += 1
			if j == 25:
				break
ans = 0
if S[0] >= 74:
	ans += 1
for i in range(3):
	if S[i] >= 24:
		tmp = -1
		for num in S:
			if num >= 2:
				tmp += 1
		ans += tmp
for i in range(4):
	if S[i] >= 14:
		tmp = -1
		for num in S:
			if num >= 4:
				tmp += 1
		ans += tmp
tmp4 = 0
tmp2 = 0
for num in S:
	if num >= 4:
		tmp4 += 1
	if num >= 2 and num < 4:
		tmp2 += 1
ans += tmp4 * (tmp4 - 1) * (tmp4 + tmp2 - 2) // 2
print(ans)


def soinsu_bunkai(m):
	pf = {}
	for i in range(2, int(m ** 0.5) + 1):
		while m % i == 0:
			pf[i] = pf.get(i, 0) + 1
			m //= i
	if m > 1:
		pf[m] = 1
	return pf
from collections import Counter
from collections import defaultdict
from itertools import permutations
import sys
input = sys.stdin.readline
N = int(input())
c = defaultdict(int)
for i in range(1, N + 1):
	x = soinsu_bunkai(i)
	for (j, v) in x.items():
		c[j] += v
ans = set()
for (p, q, r) in permutations(c.keys(), 3):
	if c[p] >= 74:
		ans.add(p ** 74)
	if c[p] >= 24 and c[q] >= 2:
		ans.add(p ** 24 * q ** 2)
	if c[p] >= 14 and c[q] >= 4:
		ans.add(p ** 14 * q ** 4)
	if c[p] >= 4 and c[q] >= 4 and (c[r] >= 2):
		ans.add(p ** 4 * q ** 4 * r ** 2)
print(len(ans))


import sys
sys.setrecursionlimit(10 ** 8)

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 li2(N):
	return [list(map(int, sys.stdin.readline().split())) for _ in range(N)]

def dp2(ini, i, j):
	return [[ini] * i for _ in range(j)]
from collections import defaultdict
from itertools import accumulate

def factorization(n):
	temp = n
	for i in range(2, int(-(-n ** 0.5 // 1)) + 1):
		if temp % i == 0:
			cnt = 0
			while temp % i == 0:
				cnt += 1
				temp //= i
			arr[i] += cnt
	if temp != 1:
		arr[temp] += 1
	if arr == []:
		arr[n] += 1
	return arr
N = ii()
arr = defaultdict(int)
for i in range(1, N + 1):
	factorization(i)
cnt = [0] * 100
for (key, value) in arr.items():
	cnt[1] += 1
	cnt[value + 1] += -1
cnt = list(accumulate(cnt))
ans = 0
if cnt[4] > 1:
	ans += cnt[4] * (cnt[4] - 1) // 2 * (cnt[2] - 2)
if cnt[24]:
	ans += cnt[24] * (cnt[2] - 1)
if cnt[14]:
	ans += cnt[14] * (cnt[4] - 1)
if cnt[74]:
	ans += cnt[74]
print(ans)


n = int(input())
d = {}
for i in range(2, n + 1):
	for j in range(2, i + 1):
		while i % j == 0:
			i //= j
			d[j] = d.get(j, 0) + 1
a = list(d.values())
dp = [[0] * 74 + [1] for i in range(len(a) + 1)]
for i in reversed(range(len(a))):
	for j in range(74):
		for k in range(a[i] + 1):
			v = j + (j + 1) * k
			if v > 74:
				break
			dp[i][j] += dp[i + 1][v]
print(dp[0][0])


N = int(input())

def solve(N):
	seventyfour = [78, 101]
	twentyfour = [28, 54, 100, 101]
	fourteen = [16, 30, 60, 91, 101]
	four = [6, 9, 20, 28, 44, 52, 68, 76, 92, 116]
	two = [4, 6, 10, 14, 22, 26, 34, 38, 46, 58, 62, 74, 82, 86, 94, 106]
	lists = [two, four, fourteen, twentyfour, seventyfour]
	nums = []
	for lis in lists:
		for (i, n) in enumerate(lis):
			if N < n:
				nums.append(i)
				break
	ans = nums[1] * (nums[1] - 1) // 2 * (nums[0] - 2) + nums[2] * (nums[1] - 1) + nums[3] * (nums[0] - 1) + nums[4]
	return ans
print(solve(N))


import sys
import math
from collections import deque
sys.setrecursionlimit(1000000)
MOD = 10 ** 9 + 7
input = lambda : sys.stdin.readline().strip()
NI = lambda : int(input())
NMI = lambda : map(int, input().split())
NLI = lambda : list(NMI())
SI = lambda : input()

def make_grid(h, w, num):
	return [[int(num)] * w for _ in range(h)]

def prime_fact(n):
	root = int(math.sqrt(n))
	prime_dict = {}
	for i in range(2, root + 1):
		cnt = 0
		while n % i == 0:
			cnt += 1
			n = n // i
		if cnt:
			prime_dict[i] = cnt
	if n != 1:
		prime_dict[n] = 1
	return prime_dict

def main():
	N = NI()
	PD = {}
	for i in range(2, N + 1):
		pd = prime_fact(i)
		for (p, k) in pd.items():
			PD.setdefault(p, 0)
			PD[p] += k
	X = {74: 0, 24: 0, 14: 0, 4: 0, 2: 0}
	for (p, k) in PD.items():
		for x in X.keys():
			if k >= x:
				X[x] += 1
	print(X[74] + X[24] * (X[2] - 1) + X[14] * (X[4] - 1) + X[4] * (X[4] - 1) // 2 * (X[2] - 2))

def __starting_point():
	main()
__starting_point()


n = int(input())
p = [0 for i in range(n + 1)]
for i in range(2, n + 1):
	t = 2
	a = i
	while t <= 10:
		if a % t == 0:
			p[t] += 1
			a //= t
		else:
			t += 1
	p[a] += 1
d = {2: 0, 4: 0, 14: 0, 24: 0, 74: 0}
for i in p[2:]:
	if i >= 2:
		d[2] += 1
	if i >= 4:
		d[4] += 1
	if i >= 14:
		d[14] += 1
	if i >= 24:
		d[24] += 1
	if i >= 74:
		d[74] += 1
print((d[2] - 2) * d[4] * (d[4] - 1) // 2 + (d[4] - 1) * d[14] + (d[2] - 1) * d[24] + d[74])


from math import factorial
from itertools import permutations
n = int(input())
np = factorial(n)
p_list = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97]
ans = []
for (s, t, u) in permutations(p_list, 3):
	num1 = s ** 4 * t ** 4 * u ** 2
	num2 = s ** 14 * t ** 4
	num3 = s ** 24 * t ** 2
	num4 = s ** 74
	for z in [num1, num2, num3, num4]:
		if np % z == 0:
			ans.append(z)
print(len(set(ans)))


n = int(input())
prime_list = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47]
d = []
e = [0, 0, 0, 0, 0]
f = [74, 24, 14, 4, 2]
for i in prime_list:
	a = n
	b = 0
	c = 1
	while a // i ** c > 0:
		b += a // i ** c
		c += 1
	else:
		d.append(b)
count = 0
len_d = len(d) - 1
for k in f:
	for (i, j) in enumerate(d):
		if j < k:
			e[count] = i
			count += 1
			break
		elif i == len_d:
			e[count] = i + 1
			count += 1
			break
print(e[0] + e[1] * (e[4] - 1) + e[2] * (e[3] - 1) + e[3] * (e[3] - 1) // 2 * (e[4] - 2))


from collections import *

def factorize(n):
	fct = []
	for i in range(2, int(n ** 0.5) + 1):
		c = 0
		while n % i == 0:
			n //= i
			c += 1
		if c > 0:
			fct.append((i, c))
	if n > 1:
		fct.append((n, 1))
	return fct
N = int(input())
cnt = defaultdict(int)
for i in range(1, N + 1):
	fct = factorize(i)
	for (p, c) in fct:
		cnt[p] += c
(ov74, ov24, ov14, ov4, ov2) = (0, 0, 0, 0, 0)
for v in cnt.values():
	if v >= 74:
		ov74 += 1
	if v >= 24:
		ov24 += 1
	if v >= 14:
		ov14 += 1
	if v >= 4:
		ov4 += 1
	if v >= 2:
		ov2 += 1
ans = ov74 + ov24 * (ov2 - 1) + ov14 * (ov4 - 1) + ov4 * (ov4 - 1) // 2 * (ov2 - 2)
print(ans)


from math import factorial
N = int(input())
fact = factorial(N)
e = [0] * (N + 1)
for i in range(2, N + 1):
	while fact % i == 0:
		e[i] += 1
		fact //= i

def num(m):
	return len(list(filter(lambda x: x >= m - 1, e)))
ans = 0
ans += num(75)
ans += num(25) * (num(3) - 1)
ans += num(15) * (num(5) - 1)
ans += num(5) * (num(5) - 1) * (num(3) - 2) // 2
print(ans)


from math import factorial
from itertools import permutations
N = int(input())
n_p = factorial(N)
p_list = [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97]
ans = []
for (p1, p2, p3) in permutations(p_list, 3):
	n1 = p1 ** 4 * p2 ** 4 * p3 ** 2
	n2 = p1 ** 14 * p2 ** 4
	n3 = p1 ** 24 * p2 ** 2
	n4 = p1 ** 74
	for v in [n1, n2, n3, n4]:
		if n_p % v == 0:
			ans.append(v)
print(len(set(ans)))


from itertools import permutations
n = int(input())
d = [0] * (n + 1)
for i in range(2, n + 1):
	for p in range(2, n + 1):
		while i % p == 0:
			i //= p
			d[p] += 1
d = list(filter(int, d))
ans = 0
for (i, j, k) in permutations(d, 3):
	ans += min(i - 2, j - 4, k - 4) >= 0
ans //= 2
for (i, j) in permutations(d, 2):
	ans += min(i - 14, j - 4) >= 0
	ans += min(i - 2, j - 24) >= 0
for i in d:
	ans += i - 74 >= 0
print(ans)


import collections
n = int(input())

def prime_factorize(n):
	a = []
	while n % 2 == 0:
		a.append(2)
		n //= 2
	f = 3
	while f * f <= n:
		if n % f == 0:
			a.append(f)
			n //= f
		else:
			f += 2
	if n != 1:
		a.append(n)
	return a
count = 0
div = {}
for i in range(2, n + 1):
	c = collections.Counter(prime_factorize(i))
	for (key, value) in list(c.items()):
		if key in div:
			div[key] += value
		else:
			div[key] = 1

def num(m):
	return len(list([x for x in list(div.values()) if x + 1 >= m]))
print(num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2)


from math import sqrt

def sieve(n):
	if n <= 4:
		return list(range(2, n))

	def _sieve_of_eratosthenes(n):
		limit = int(sqrt(n)) + 1
		(*table,) = [1] * n
		table[0] = table[1] = 0
		for i in range(2, limit):
			if table[i]:
				for j in range(i ** 2, n, i):
					table[j] = 0
		return [i for i in range(2, n) if table[i]]
	return _sieve_of_eratosthenes(n)

def factorint(n):
	d = {}
	for i in range(2, int(sqrt(n)) + 1):
		c = 0
		(q, r) = divmod(n, i)
		while not r:
			c += 1
			n = q
			(q, r) = divmod(n, i)
		if c:
			d[i] = c
	if n != 1:
		d[n] = 1
	return d
n = int(input())
P = sieve(n + 1)
d = {p: i for (i, p) in enumerate(P)}
X = [1] * len(P)
for i in range(2, n + 1):
	for (k, v) in factorint(i).items():
		X[d[k]] += v
nb_3 = len([x for x in X if x >= 3])
nb_5 = len([x for x in X if x >= 5])
nb_15 = len([x for x in X if x >= 15])
nb_25 = len([x for x in X if x >= 25])
nb_75 = len([x for x in X if x >= 75])
print(nb_75 + nb_25 * (nb_3 - 1) + nb_15 * (nb_5 - 1) + nb_5 * (nb_5 - 1) * (nb_3 - 2) // 2)


A = int(input())
dict_f = {}

def divisor(N):
	l = {}
	for i in range(2, N + 1):
		cnt = 0
		while N % i == 0:
			cnt += 1
			N //= i
		if cnt > 0:
			l[i] = cnt
	return l
for i in range(2, A + 1):
	D = divisor(i).items()
	for (j, k) in D:
		try:
			dict_f[j] = dict_f[j] + k
		except KeyError:
			dict_f[j] = k
dict_f = dict_f.values()

def num(N):
	return len(list(filter(lambda x: x >= N - 1, dict_f)))
print(num(75) + num(25) * (num(3) - 1) + num(15) * (num(5) - 1) + num(5) * (num(5) - 1) * (num(3) - 2) // 2)