Using the
BigInteger[
^] Structure you might accomplish the task.
Namely (you should have a big big big console.... :-) ):
class Program
{
public static BigInteger fact(Int32 n)
{
BigInteger f = new BigInteger(n);
while (--n > 1)
{
f *= n;
}
return f;
}
static void Main(string[] args)
{
BigInteger f = fact(10000);
Console.WriteLine(f.ToString());
}
}