remove recursion in combine()