Add sumlines function.