How will I insert a line "abcdef" at every 100th line of a file?

Answer Posted / aayan

sed '1~100iabcdef' filename.txt

Is This Answer Correct ?    16 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is bash a shell script?

589


What's the difference between scripting and coding?

585


How do I run a script from command prompt?

551


What is a scripting language simple definition?

543


What is the use of .sh file?

591






Write a script to print the first 10 elements of fibonacci series.

1746


What is shell and terminal?

562


How can I send a mail with a compressed file as an attachment?

544


Why is the use of shell script?

533


How would you compare the strings in a shell script?

538


What is mac default shell?

602


How do we create command aliases in a shell?

526


What is bash used for?

567


how to print the 2-d, 3-d arrays in unix shell script programs please answer thi questio to my mail venusaikumar@gmail.com

2094


Write down the syntax for all the loops in shell scripting.

642