I have implemented a helper procedure, called predmap (Note: I am not aware of (filter) before writing this exercise). It's identical to map, but the function argument is a predicate. The item will be added in the new list if the predicate is true.
I have implemented a helper procedure, called predmap. It's identical to map, but the function argument is a predicate. The item will be added in the new list if the predicate is true.
I have implemented a helper procedure, called predmap (Note: I am not aware of (filter) before writing this exercise). It's identical to map, but the function argument is a predicate. The item will be added in the new list if the predicate is true.
In the second argument to cons, I put the if statement in the function argument directly to avoid repeating the call to predmap in the code. But it seems to look commplecatedcomplicated now.
In the second argument to cons, I put the if statement in the function argument directly to avoid repeating the call to predmap in the code. But it seems to look commplecated now.
In the second argument to cons, I put the if statement in the function argument directly to avoid repeating the call to predmap in the code. But it seems to look complicated now.