This has the exact same idea with the earlier JavaScript post with almost the same title. In this, I "translated" the JavaScript language into Python language. Python #result flag def check(b, f): for i, val_ref in enumerate(b): for j, val in enumerate(b): if (i Added shorter version April 22, 2015 Shorter version def r_d(a): b = a[0:len(a)] #copy array buffer = [] dummy = "deleted" #dummy string for i, val_ref in enumerate(b): for j, val in enumerate(b): if (i #1 Result in Python's command terminal (1 st version) #2 Result in Python's command terminal (shorter version) This will leave the original array (list) intact, no changes.