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: Wrong Answer)

using System;
using System.Collections.Generic;

namespace ABC114_D___756
{
    class Program
    {
        static void Main(string[] args)
        {
            var N = int.Parse(Console.ReadLine());
            var isPrime = new bool[N + 1];
            for (int i = 0; i < N + 1; i++) isPrime[i] = true;
            isPrime[0] = false;
            isPrime[1] = false;

            for (int i = 2; i < Math.Pow(N, 0.5); i++)
            {
                if (!isPrime[i]) continue;
                for (int j = i + 1; j < N + 1; j++) if (j % i == 0) isPrime[j] = false;
            }

            var factoring = new Dictionary<int, int>();
            for (int i = 2; i < N + 1; i++) if (isPrime[i]) factoring.Add(i, 0);

            int[] primes = new int[factoring.Keys.Count];
            factoring.Keys.CopyTo(primes, 0);

            for (int i = 2; i <= N; i++)
            {
                foreach (int j in primes)
                {
                    var temp = j;
                    if (i < j) break;
                    while (i % temp == 0)
                    {
                        factoring[j] += 1;
                        temp *= j;
                    }
                }
            }

            var count23 = 0;
            var count4over = 0;
            var count14over = 0;
            var count24over = 0;
            var count74over = 0;

            foreach (int item in factoring.Values)
            {
                if (item == 2 || item == 3) count23 += 1;
                if (item >= 4) count4over += 1;
                if (item >= 14) count14over += 1;
                if (item >= 24) count24over += 1;
                if (item >= 74) count74over += 1;
            }

            var result = 0;
            result += count23 * count4over * (count4over - 1) / 2;
            result += count4over * (count4over - 1) * (count4over - 2) / 6;
            result += count14over * (count4over - 1);
            result += count24over * (count4over + count23 - 1);
            result += count74over;
            Console.WriteLine(result);
        }
    }
}