User: colin -- 2012-07-03 << 965 967 >> |
Hits: 3542 |
Type: Count and statistics |
Search all Count and statistics examples |
Description: |
How to count the number of lines under each specified pattern? |
Input Sample: |
lesn1 quiz 7.00/14.00 8.00/14.00 9.00/14.00 13.00/14.00 0.00/14.00 lesn2 quiz 10.00/15.00 12.00/15.00 |
Output Sample: |
lesn1 quiz 5 lesn2 quiz 2 |
Answer: |
Hint: You need to Download and install "Replace Pioneer" on windows platform to finish following steps. |
1. open "Tools->Batch Runner" menu 2. drag multiple text file to "Batch Runner" window 3. click "Fast Replace" button 4. click "Add" to add new rule * set "search" to: * set "replace" to: * click "ok" 5. make sure "reg exp" option is check. 6. click "start", done! Note: * you need to make backup in advance to avoid original files being overwritten. * if you don't want to change original file, only want to generate an output, you can select "output to single file" in last step. * if there are other non related text in each file and you want to ignore them, you can check option of "extract" in step 5. |
Screenshot 1: Fast_Replace_Window |