if we create a file, in that 10 rows(means 1,2,....9,10
like). i want 7 row exactly, which command use in unix?
plz send this question.

Answer Posted / krishna reddy

sed -n '7p' <filename>

or
head -8 <filename>|tail -1

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Write a command to display a file’s contents in various formats?

629


What is grep short for?

558


What is rmdir command?

555


How do I search for a file in unix command?

549


What is command statement?

543






Name the general commands in using unix os for a beginner?

625


What is the command to find maximum memory taking process on the server?

674


Which command is used to delete all files in the current directory and all its sub-directories?

671


What is difference between grep and find command in unix?

582


Write a command that will allow a unix system to shut down in 15 minutes, after which it will perform a reboot.

628


What is the behavioural difference between cmp and diff commands?

677


What does pipe () return?

598


Write a command to kill the last background job?

620


How to display no of records in oracle using unix command?

590


How do I use grep to search for a file?

584