index = 0 innerIndex = 0 list item itemCategory roll (loop (ls index (count list)) (if (eq (item index list) itemCategory) (block (innerList) (setq innerList (item (add 1 index))) (loop (ls innerIndex (count innerList)) (if (ls roll (item innerIndex innerList) (enhance item (item (add 1 innerIndex) innerList) ;break the inner loop (setq innerIndex 50000) ) (setq innerIndex (add 2 innerIndex)) ) ;break the outter loop (setq index 50000) ) ) (setq index (add 2 index)) )