How i'll delete a particular line from the file? Please give
answer as soon as possible. Thanks in advance.

Answer Posted / ranjan tikoo

If I have 10 lines in the file and I want to delete line 5
and 6 then use

sed '5,6 d' temp1.txt > temp2.txt

Is This Answer Correct ?    2 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Enumerate some of the most commonly used network commands in unix?

614


What is the difference between cat command and more command?

599


What does grep v do?

557


What command will change your prompt to myprompt?

697


What is the use of the command 'ls -x chapter[1-5]' ?

659






What are some command words?

559


What does sed command do in unix?

558


Differentiate cmp command from diff command.

586


What is the use of cut command in unix?

690


What is difference between grep and find command in unix?

577


What are the dos commands?

644


What is awk used for?

616


Give the command for finding the current date.

579


Is ‘du’ a command? If so, what is its use?

633


How do I use grep to search for a file?

578