Help for this page

Select Code to Download


  1. or download this
     perl -i.bak -F, -ane '
        if ($F[0]+1 == $F[1] and $F[1]+1 == $F[2]) {warn "row $.: $_"} els
    +e {print}
    ' file.csv 2>file.log
    
  2. or download this
    for line in file: 
        for i in range(1,4):
            if ($F[0]+ i == $F[1] and $F[1]+i == $F[2]): 
               remove line