Use mapcar instead of loop.