Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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

Answer Posted / radhakant kumar

awk '{if(NR==1) print $0}' filename

Is This Answer Correct ?    9 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Which command is used to kill the last background job?

1337


What is the first character of the output in ls l command?

1216


Who command in unix operating system?

1142


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

1238


What is time_t?

1118


How do I use grep to find a file?

1117


How to find $ai_serual resolved path by using unix

1762


What is the pipe command?

1197


What is the command to compare two files in unix?

1127


What is the behavioural difference between cmp and diff commands?

1289


What is the use of the tee command?

1100


Enlist some filename manipulation commands in unix.

1162


What is awk good for?

1144


Which command is used to copy files?

1179


What are bash commands?

1170