Like A Duck@programming.dev to Programmer Humor@programming.dev · 2 years agoif else if else if elseprogramming.devimagemessage-square25fedilinkarrow-up1863arrow-down123file-text
arrow-up1840arrow-down1imageif else if else if elseprogramming.devLike A Duck@programming.dev to Programmer Humor@programming.dev · 2 years agomessage-square25fedilinkfile-text
minus-squareKogasa@programming.devlinkfedilinkarrow-up3·2 years agoThat’s just “recurrence.” The same as a “while” loop. Recursion is specifically when a procedure invokes itself.
minus-squareMagicShel@programming.devlinkfedilinkarrow-up2·2 years agoFair enough. Point is nothing is getting smaller except the call stack.
minus-squareKogasa@programming.devlinkfedilinkarrow-up4·2 years agoThe thing that’s getting smaller is the “complexity” or “distance from the trivial case” of the function invocation. This is an informal notion though.
That’s just “recurrence.” The same as a “while” loop. Recursion is specifically when a procedure invokes itself.
Fair enough. Point is nothing is getting smaller except the call stack.
The thing that’s getting smaller is the “complexity” or “distance from the trivial case” of the function invocation. This is an informal notion though.