Replace Pioneer Home   All Examples   Free Download

 New request --free  RSS: Replace Pioneer Examples

540.Text generator -- How to duplicate each line 5 times in a text file?

User: editor -- 2010-06-19
Hits: 69
Type: Text generator   
Search all Text generator examples
Description:
How to duplicate each line 5 times in a text file?
Input Sample:
line1
line2
line3
...
Output Sample:
line1
line1
line1
line1
line1
line2
line2
line2
line2
line2
line3
line3
line3
line3
line3
...
Answer:
Hint: You need to Download and install "Replace Pioneer" to finish following steps.
1. ctrl-o open source text file
2. ctrl-h open replace window
* set 'replace unit' to 'Line'
* enter following in "Replace with pattern" entry:

3. click 'Replace',done!
4. ctrl-s save to file.

Similar Examples:
How to delete duplicate lines of a text file? (76%)
How to duplicate every letter of a-z and A-Z in a text file? (71%)
How to sort and delete duplicate lines of a text file? (71%)
How to shuffle all the lines in a text file? (69%)
How to add line_no before each line of a text file? (68%)
How to remove partially duplicated lines in a text file? (67%)
How to delete the first word in each line in a text file? (67%)
How to remove/delete unnecessary line breaks in a text file? (64%)

Check Demo of Text generator