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...

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 / meenu

if u want first 7 rows then
head -n7 <filename>
but if you want only 7th row then
awk 'nr==7 {print}' <fileanme>
or
tail -n4 <filename>|head -n1

Is This Answer Correct ?    0 Yes 6 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain mount and unmount command.

1234


Which unix command lists files/folders in alphabetical order?

1776


How do I run a bash script?

1196


What are reported commands?

1141


What are file commands?

1244


What does 'mkdir' command do in UNIX?

1323


What will the following command do?

1132


Give the command for finding the current date.

1133


What is the difference between cat and more command?

1316


How do I use grep to find a file?

1123


Does cp command overwrite files?

1219


Is there any method to erase all files in the current directory, along with its all sub-directories, by using only one command?

1239


Why is it called grep?

1040


What is the use of finger command?

1225


What command will change your prompt to myprompt?

1336