Add tasks for all the new languages
This commit is contained in:
parent
9dc3c2bb62
commit
bba7bfd280
13208 changed files with 134745 additions and 0 deletions
19
Task/Mutual-recursion/Ring/mutual-recursion.ring
Normal file
19
Task/Mutual-recursion/Ring/mutual-recursion.ring
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
see "F sequence : "
|
||||
for i = 0 to 20
|
||||
see "" + f(i) + " "
|
||||
next
|
||||
see nl
|
||||
see "M sequence : "
|
||||
for i = 0 to 20
|
||||
see "" + m(i) + " "
|
||||
next
|
||||
|
||||
func f n
|
||||
fr = 1
|
||||
if n != 0 fr = n - m(f(n - 1)) ok
|
||||
return fr
|
||||
|
||||
func m n
|
||||
mr = 0
|
||||
if n != 0 mr = n - f(m(n - 1)) ok
|
||||
return mr
|
||||
Loading…
Add table
Add a link
Reference in a new issue