Weird recursive algorithms
craftofcoding.wordpress.com