def add_line_increment(lines, lineModified, diference, atLineStart=False):
 def _inner_increment(line):
  if (((not atLineStart) and (line <= lineModified)) or (lineModified == (line + diference))):
   return line
  return (line + diference)
 return list(map(_inner_increment, lines))

def add_line_increment ( lines , lineModified , diference , atLineStart = False ) : def _inner_increment ( line ) : if ( ( ( not atLineStart ) and ( line <= lineModified ) ) or ( lineModified == ( line + diference ) ) ) : return line return ( line + diference ) return list ( map ( _inner_increment , lines ) )
increment the line number of the list content when needed .