母牛的问题怎么算?
我有一道数学题:有一头母牛,它每年年初生一头小母牛.每头小母牛从第四个年头开始,每年年初也生一头小母牛.请问第n年时共有多少头母牛?
母牛的问题怎么算?我有一道数学题:有一头母牛,它每年年初生一头小母牛.每头小母牛从第四个年头开始,每年年初也生一头小母牛
答案:1 悬赏:50 手机版
解决时间 2021-04-11 18:47
- 提问者网友:鐵馬踏冰河
- 2021-04-11 08:36
最佳答案
- 五星知识达人网友:撞了怀
- 2021-04-11 10:11
f[0] = 1; f[1] = 2; f[2] = 3;
f[x_] := f[x - 1] + f[x - 3]
程序解得:
{年,牛数}
{0,1},
{1,2},
{2,3},
{3,4},
{4,6},
{5,9},
{6,13},
{7,19},
{8,28},
{9,41},
{10,60},
{11,88},
{12,129},
{13,189},
{14,277},
{15,406},
{16,595},
{17,872},
{18,1278},
{19,1873},
{20,2745},
{21,4023},
{22,5896},
{23,8641},
{24,12664},
{25,18560},
{26,27201},
{27,39865},
{28,58425},
{29,85626},
{30,125491},
{31,183916},
{32,269542},
{33,395033},
{34,578949},
{35,848491},
{36,1243524},
{37,1822473},
{38,2670964},
{39,3914488},
{40,5736961},
{41,8407925},
{42,12322413},
{43,18059374}
不好意思,离散数学我没学过.
我要举报
如以上问答信息为低俗、色情、不良、暴力、侵权、涉及违法等信息,可以点下面链接进行举报!
大家都在看
推荐资讯