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

In a file , how to retrieve the lines which are the
multiples of 50 ? like 50,100,150th lines etc.

Answer Posted / abhishek

awk 'NR % 2 == 0 {print}' abc.txt

Is This Answer Correct ?    3 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

c program the catches the ctrl-c(SIGINT) Signal for the first time and prints a output rather and exit on pressing Ctrl-C again

6464


What is a scripting language simple definition?

1109


What is sh in shell script?

1035


one folder contains lot of students name but I want to fetch hello with every student name individually using shell script

963


How are shells born?

976


What are zombie processes?

1035


What is shell chemistry?

992


What are the advantages of shell script?

1033


Explore about environment variables?

1052


What is a shell in operating system?

1111


How can I set the default rwx permission to all users on every file which is created in the current shell?

1433


How can any user find out all information about a specific user like his default shell, real-life name, default directory, when and how long he has been using the system?

1108


Write a command sequence to find all the files modified in less than 2 days and print the record count of each.

1521


I want to monitor a continuously updating log file, what command can be used to most efficiently achieve this?

1360


write a shell script to emulate the Id command of PRIMOS which lists files and directories. It list files first with a header FILES and then directories with a header DIRECTORIES. This command has several options. The main ones are. -file select files only -dir select directories only -reverse sort in reverse order -no_header put no header on the output -brief output the header only -size display the size of each file -help display Id´s syntax and options.

2791