• Home
  • Random
  • Recent changes
  • Special pages
  • Settings
  • About MOASSpedia
  • Disclaimers
MOASSpedia
  • 216.73.216.154
  • Talk
  • Watchlist
  • Contributions
  • Log in

Template:Simple recursion

Template Discussion
  • Language
  • Watch
  • History
  • Edit
    • Page information
    • Permanent link
    • What links here
Template documentation[view] [edit] [history] [purge]
This template uses Lua:
  • Module:String


Usage

{{{Simple recursion|left repeated text|non-repeated text|right repeated text|depth}}

Example

  • "{{Simple recursion|a|b|c|4}}" gives "aaaabcccc"
  • "{{Simple recursion|f( |f(x) + g|) + g|7}}" gives "f( f( f( f( f( f( f( f(x) + g) + g) + g) + g) + g) + g) + g) + g"
  • {{math|[[Golden ratio|<var>φ</var>]] &asymp; {{#expr: {{Simple recursion|(|1|)^-1+1|35}}}}}}" gives "φ ≈ 1.6180339887499" (iterative method, finding the largest of the solutions to φ − 1 = φ − 1 {\displaystyle \varphi ^{-1}=\varphi -1} {\displaystyle \varphi ^{-1}=\varphi -1})

See also

  • Template:Loop (backlinks edit)
  • Template:For loop (backlinks edit)
The above documentation is transcluded from Template:Simple recursion/doc. (edit | history)
Editors can experiment in this template's sandbox (create | mirror) and testcases (create) pages.
Add categories to the /doc subpage. Subpages of this template.
Retrieved from "https://moasspedia.org/w/index.php?title=Template:Simple_recursion&oldid=30986"
Categories:
  • Templates based on the String Lua module
  • Typing-aid templates
Last edited on 23 September 2018, at 11:52

MOASSpedia

Content is available under Creative Commons Attribution-ShareAlike unless otherwise noted.
  • This page was last edited on 23 September 2018, at 11:52.
  • Content is available under Creative Commons Attribution-ShareAlike unless otherwise noted.
  • Privacy policy
  • About MOASSpedia
  • Disclaimers
  • Desktop