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

Create a bash shell script to sort and then
uniq the file from the command line & store it to a new
file and output the results to the screen. Name this
script "sortAndUniq.sh"

Answer Posted / linuxdemon

sort $1 | uniq > output | echo "`cat output`"

Is This Answer Correct ?    1 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What does it mean to debug a script?

1002


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

1453


What is bash command used for?

1017


What are the default permissions of a file when it is created?

962


What is sed in shell script?

989


What is the syntax of while loop in shell scripting?

986


What is a batch file used for?

1039


How do I run a script on mac?

1040


Differentiate between ‘ and ” quotes.

1101


What are the advantages of shell scripting?

991


State the advantages of shell scripting?

1017


In my bash shell I want my prompt to be of format '$"present working directory":"hostname"> and load a file containing a list of user-defined functions as soon as I log in, how will you automate this?

1083


What does echo mean in scripting?

961


What is a shell script? Can you name some of its advantages?

984


What is the default ubuntu terminal?

1061