Simple recursive function

Simple recursive function - 消息

#1 已发布: 2021/10/20 16:26:18
Patukott

Patukott

0个赞,共6个帖子。

组: User

Hello!

I am trying to write a simple recursive function, but cannot understand how to do it in Smath. It gives me an error saying the function is not defined. Picture of the problem is attached below.

Capture.PNG
#2 已发布: 2021/10/20 17:44:28
Jean Giraud

Jean Giraud

983个赞,共6,866个帖子。

组: User

... like this ?

Unk.PNG
#3 已发布: 2021/10/20 19:26:17
overlord

overlord

600个赞,共1,381个帖子。

组: Moderator

Wrote

I am trying to write a simple recursive function, but cannot understand how to do it in Smath.


Use line().
But remember, recursion has an intended limit.
After 50 steps, it won't calculate.

Regards

2021-10-20_23-29.png
1位用户喜欢此帖子
sergio 2021/10/21 10:19:00
#4 已发布: 2021/10/21 05:16:05
Patukott

Patukott

0个赞,共6个帖子。

组: User

Yes, Thank you! This was what I was looking for.
  • 有新帖
  • 无新帖