recursive implementation complete