Problem:
Score : 400 points

Problem Statement

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 1

9

Sample Output 1

0

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

Sample Input 2

10

Sample Output 2

1

There is one Shichi-Go number among the divisors of 10! = 3628800: 32400.

Sample Input 3

100

Sample Output 3

543

Solution in C# (Mono 4.6.2.0) (judge verdict: Accepted)

//#define TEST
using System;
using System.Collections.Generic;
using System.Linq;
class P{
    private static int[] ps = {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}; //長さ25
    static void Main(){
        int[] pc = new int[25];
        int n = int.Parse(Console.ReadLine()); //入力を受け取る
        for (int i = 2;i <= n;i++){ //n!の素因数分解
            foreach (var p in ps){
                int ic = i;
                while (ic % p == 0){
                    ic /= p;
                    pc[invP(p)]++;
                }
            }
        }
#if TEST
        foreach (var i in pc)
            Console.WriteLine(i);
#endif
        //3,5,15,25,75以上の個数を調べる
        var q5 = from x in pc
                where x + 1 >= 5
                select x;
        int c5 = q5.Count();
        var q3 = from x in pc
                where x + 1 >= 3
                select x;
        int c3 = q3.Count();
        var q15 = from x in pc
                where x + 1 >= 15
                select x;
        int c15 = q15.Count();
        var q25 = from x in pc
                where x + 1 >= 25
                select x;
        int c25 = q25.Count();
        var q75 = from x in pc
                where x + 1 >= 75
                select x;
        int c75 = q75.Count();
        //答えを計算
        int ans = 0;
        { //5 * 5 * 3
            if (c5 > 1)
                ans += (c5 * (c5 - 1) / 2) * (c3 - 2);
        }
        { // 5 * 15
            ans += c15 * (c5 - 1);
        }
        { // 3 * 25
            ans += c25 * (c3 - 1);
        }
        { //75
            ans += c75;
        }
        Console.WriteLine(ans);
    }
    static int invP(int p){
        for (int i = 0;i < 25;i++)
            if (ps[i] == p)
                return i;
        return -1;
    }
}