minus-squaremercator_rejection@programming.devtoProgramming@programming.dev•when is it best to use a recursive function vs a for looplinkfedilinkarrow-up8·11 months agoAny recursive algorithm can be made iterative and vise versa. It really depends on the algorithm if the function calls are a major factor in performance. linkfedilink
minus-squaremercator_rejection@programming.devtoLinux@lemmy.ml•Ackchyually, not every Linux is a GNU Linuxlinkfedilinkarrow-up8arrow-down1·1 year agoThese examples didn’t actually clear anything up for me 🙃 linkfedilink
Any recursive algorithm can be made iterative and vise versa. It really depends on the algorithm if the function calls are a major factor in performance.