add recursion and skeleton of random