Problem:
Score : 300 points

Problem Statement

You are given an integer N.
Find the number of the positive divisors of N!, modulo 10^9+7.

Constraints

1≤N≤10^3

Input

The input is given from Standard Input in the following format:

N

Output

Print the number of the positive divisors of N!, modulo 10^9+7.

Sample Input 1

3

Sample Output 1

4

There are four divisors of 3! =6: 1, 2, 3 and 6. Thus, the output should be 4.

Sample Input 2

6

Sample Output 2

30

Sample Input 3

1000

Sample Output 3

972926972

Solution in C# (Mono 4.6.2.0) (judge verdict: Time Limit Exceeded)

using System;
class Program
{
	static void Main()
	{
	  long n = int.Parse(Console.ReadLine());
    long answer = 1;
    long[] divideNum = new long[1000];//素因数の個数

    for(int i = 0; i < 1000; i++) divideNum[i] = 1;

    for(long i = 2; i <= n; i++)
    {
      for(long j = 2; j <= i; j+=0)
      {
        if(i % j == 0)
        {
        divideNum[j-1] ++;//素因数を加算
        i /= j;
          if(i == 1) break;
        }else
        {
          j++;
        }
      }
    }

    for(int i = 0; i < 1000; i++)
    {
    answer *= divideNum[i];
    answer %= 1000000007;
    }

	   Console.WriteLine(answer);//WriteLineをWriteとすると、改行なしで出力。
	}
}