User:Aeldrion/Guides/Recursion

Recursion is a method of solving a problem where the solution depends on solutions to smaller instances of the same problem. In Minecraft data packs, recursive functions or function chains can be used to create loops of arbitrary length, which can have a wide number of applications: for example, recursive functions are often used for raycasting purposes. It is also used in several of my own data packs for mathematical purposes such as square root computing for AESTD), or to parse through data structures in Aetlas.

I have compiled a list of useful resources for Minecraft data pack engineers who are willing to learn more about this principle and its use cases: see Recursive functions in data packs