/* cs */ /* * Problem : DIVISOR * Contest : UOI-2006 (Dnepropetrovsk) * Type : Solution * Date : March 25, 2006 * Author : Shamil Yagiyayev * Language : C# * Compiler : .NET 1.1 * Algorithm: Simple Solution */ using System; using System.IO; class Divisor { static readonly string FILE_IN = "divisor.dat"; static readonly string FILE_OUT = "divisor.sol"; static int ReadData() { StreamReader sr = new StreamReader(FILE_IN); string line = sr.ReadLine(); return int.Parse(line); } static long Process(int n) { long f = 1; for (int i=2;i<=n;i++) f*=i; long result=0; for (long i=1;i<=f;i++) if (f % i == 0) result++; return result; } static void WriteSolution(long result) { StreamWriter sw = File.CreateText(FILE_OUT); sw.WriteLine("{0}", result); sw.Close(); } static void Main() { int n = ReadData(); WriteSolution(Process(n)); // for (int i=1; i<=20; i++) // { // Console.Write(i); // Console.WriteLine(" {0}", Process(i)); // } } }