This is HtDP Excercise 12.4.2.:
Here is the tests iI conducted:
So itIt works. But, but I think this is not the way it was supposed to be solved. In their hint, they ask to use only recursion anand append., but I didn't really get it. Could someone suggest a better answer.?