double-and-add shit as an 'unfold'

** NOT TESTED NOR DRY RUN **
functional programming ftw!
Merge pull request #1 from banacorn/patch-1

double-and-add shit as an 'unfold'