A file has 1000 lines and i want to display only 1st line
how to do it?
pls ..tel me

Answer Posted / namdeo patil

head -n 1 filename

Is This Answer Correct ?    8 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What happens when we execute a unix command?

613


How do I find previous commands in unix?

607


What is the command to view process running?

586


What is time_t?

598


Why is shebang used?

606






hw will u use awk in replacing cahrs and files

2743


Which unix command lists files/folders in alphabetical order?

624


Write a command to kill the last background job?

628


What do know about tee command and its usage?

603


How can we use grep command in unix?

623


Explain the steps that a shell follows while processing a command.

693


What's a command word?

599


What is the command to find hidden files in the current directory?

601


How do you repeat a command in terminal?

602


How do I search a whole word in vim?

704