Tag Archives: recursion

Bonfire 04: Factorialize a Number


TASK: Return the factorial of the provided integer. A recursive function is a function that calls itself until it doesn’t. In this case, it multiplies num * (num-1) until (num-1) = 0, when it multiplies the number obtained so far by 1. Resources: unicodegirl: Example of Recursion Quora: What is the best way to explain […]

https://codedmalarkey.wordpress.com/2015/08/12/bonfire-03-factorialize-a-number/

Sorting part 2


Now let’s try to implement some other sorting algorithms. Let’s start with selectsort. We have a list of elements that we want to sort. We can divide it into two parts, sorted and unsorted.  In selectsort in each step we have to select smallest element from the unsorted part of the list and put it […]

http://mikemodzelewski.com/2015/07/05/sorting-part-2/