问问你们的王老师去
解决方案 »
- Winform DataGridView问题,各路英雄请留步,过来瞧瞧...
- pdf文件打印(C#)
- C# 如何把控件 treeView1的值 copy一份给 treeView1?要值传递 急用
- winform(c#)怎样实现批量图片浏览
- 如何获得数据库中指定表的全部字段
- 哪儿可以下载椭圆加密算法程序?
- 学了10天C#写的类,请大家多多指点。(正在完善中.........)
- 解析百度api得到的JSon里有unicode字符的问题
- 开山第二帖:有点难度!!!有用过xml的可以进来看看,dataset.readxml namespace 列名重复问题。
- 关于treeview的问题!!!!
- 移动设备mobile6开发mapxmobile同时使用UDP数据传输时的问题
- cookiecontainer 对象如何保存到文本?
using System.Collections.Generic;
using System.Text;namespace ConsoleApplication43
{
class Program
{
static void Main(string[] args)
{
Console.WriteLine(GetItem(0)); // 2.71825396825397
Console.Read();
} static double GetNM(int M)
{
if (M == 0 || M == 1)
return 1;
return M * GetNM(M - 1);
} static double GetItem(int N)
{
double Item = 1 / GetNM(N);
if (Item < 10E-5)
return 0;
else
return Item + GetItem(N + 1);
}
}
}