Hongmu Notes

2️⃣ Text filter even lines

Paste the text and take out the even-numbered lines by line number (lines 2, 4, 6…).

Text filter even lines

Instructions for use

  • Paste multiple lines of text and click "Start Processing" to extract even-numbered lines by line number.
  • If you want to get the other half, please use the "Text Filter Odd Lines" tool
  • All is done locally in the browser, and the input content will not be uploaded.

even row list

Organize the even-numbered lines into a separate list for easy comparison with the list of odd-numbered lines: the sum of the two lines equals the original text, which is clear to check.

📌 How to compare two lists

Save the even-numbered lines first, then save the odd-numbered lines, and then alternately splice them line by line and compare them with the original text. If the splicing result is completely consistent with the original text, it means that there are no missing lines or misalignments in the two lists.

📌 How is the line number calculated?

Count in natural order starting with the first row: row 1 is an odd row, row 2 is an even row, and so on. A blank line also occupies a line number, so the position of the blank line will directly affect the parity of subsequent lines. It is recommended to confirm the blank line status of the original text before processing; if the original text has a line break at the end, the last line will not be regarded as an extra line.

🧭 What scenarios are it commonly used in?

Splitting a text into two parts based on line numbers, sampling from a large text at fixed intervals, and checking whether the exported two columns of data are aligned row by row, all use alternate row sampling. This page takes even-numbered rows, and a copy of "Get odd-numbered rows" can be completely split. The sum of the number of rows in the two results should be equal to the number of rows in the original text, which can be used to check whether there are any missing rows.

All keywords and tutorials 12

❓ FAQ

Is it normal for there to be blank lines in the list?
Normal. When the even-numbered lines in the original text are blank lines, blank lines will appear in the list. You can use the Delete Blank Lines tool to clean them.
Can I mark it by line number?
No. The output is only the line content without line numbers.
How to perform integrity check on even-numbered row list
Add the number of lines in the two lists and compare them with the total number of lines in the original text. If they are equal, they are complete.