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 / niranjan
To display first 7 lines of file:-
1) head -7 filename
2) cat filename|head -7
To display only 7th line of file:-
1) head -7 filename|tail -1
2) cat filename|head -7|tail -1
3) tail +7 filename|head -1
choice is ur's..Which one u feel looks gud...:):):)
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
What is “chmod” command?
What is the general format of unix command syntax?
What is unix command line?
What is in grep command?
What does 'mkdir' command do in UNIX?
How do I open a port?
What is the function of grep command in unix?
Who invented grep?
What is grep command in unix with examples?
What is the behavioural difference between cmp and diff commands?
What does the md command do?
Who wrote grep?
Which command is used to create a directory?
Explain ‘system calls’ with respect to unix commands?
What does the command '$ls | wc –l > file1' do?