a.Write a non-recursive shell script which accepts any number of arguments and printsthem in the reverse order (For example, if the script is named rags, then executing args A B C shouldproduce C B A on the standard output).b. Write a shell script that accepts two file names as arguments, checks if the permissions for these files are identical and if the permissions are identical, output common permissions and otherwise output each file name followed by its permissions.
a.Write a shell script that takes a valid directory name as an argument and recursivelydescend all the subdirectories, finds the maximum length of any file in that hierarchyand writes this maximum value to the standard output.b. Write a shell script that accepts a path name and creates all the components in that path name asdirectories. For example, if the script is named mpc, then the command mpc a/b/c/d should createdirectories a, a/b, a/b/c, a/b/c/d.
a. Write a shell script which accepts valid log-in names as arguments and prints their corresponding homedirectories, if no arguments are specified, print a suitable error message.b. Write shell script to implement terminal locking (similar to the lock command). It should prompt the user for a password. After accepting the password entered by the user, it must prompt again for the matching password as confirmation and if match occurs, it must lock the keyword until a matchingpassword is entered again by the user, Note that the script must be written to disregard BREAK,control-D. No time limit need be implemented for the lock duration.
a. Create a script file called file-properties that reads a file name entered and outputs it properties.b. Write a shell script that accept one or more filenames as argument and convert all of them to uppercase, provided they exist in current directory.
a. Write a shell script that displays all the links to a file specified as the first argument to the script. The second argument, which is optional, can be used to specify in which the search is to begin. If thissecond argument is not present, the search is to begin in current working directory. In either case, thestarting directory as well as all its subdirectories at all levels must be searched. The script need notinclude any error checking.b. Write a shell script that accepts as filename as argument and display its creation time if file exist and ifit does not send output error message.
a.Write a shell script to display the calendar for current month with current date replaced by * or **depending on whether the date has one digit or two digits.b. Write a shell script to find smallest of three numbers that are read from keyboard.
a.Write a shell script using expr command to read in a string and display a suitablemessage if itdoes not have at least 10 characters.b. Write a shell script to compute the sum of number passed to it as argument on command line anddisplay the result.
a.Write a shell script that compute gross salary of an employee, accordingly to rulegiven below.If basic salary is < 15000 then HRA=10% of basic 7 DA=90% of basic.If basic salary is >=15000 then HRA=500 of basic & DA=98% of basic.b. Write a shell script that delete all lines containing a specific word in one or more file supplied asargument to it.
a. Write a shell script that gets executed displays the message either “Good Morning” or “Good Afternoon” or “Good Evening” depending upon time at which the user logs in. b. Write a shell script that accept a list of filenames as its argument, count and report occurrence of each word that is present in the first argument file on other argument files.
a.Write a shell script that determine the period for which a specified user is working on system.b.Write a shell script that reports the logging in of a specified user within one minute after he/she log in.The script automatically terminate if specified user does not log in during a specified period of time.
a. Write a shell script that accepts two integers as its argument and compute the value of first numberraised to the power of second number.b. Write a shell script that accept the file name, starting and ending line number as anargument anddisplay all the lines between the given line number.
a. Write a shell script that folds long lines into 40 columns. Thus any line that exceeds40 characters must be broken after 40th, a “\\” is to be appended as the indication of folding and theprocessing is to be continued with the residue. The input is to be supplied through a text file created bythe user.b. Write an awk script that accepts date argument in the form of mm-dd-yy and displays it in the form ifday, month, and year. The script should check the validity of the argument and in the case of error,display a suitable message.
a. Write an awk script to delete duplicated line from a text file. The order of the original lines mustremain unchanged.b. Write an awk script to find out total number of books sold in each discipline as well as total book soldusing associate array down table as given below.i. Electrical34ii. Mechanical67iii. Electrical80iv. Computer Science43v. Mechanical65vi. Civil198vii. Computer Science64
Write an awk script to compute gross salary of an employee accordingly to rule given below.If basic salary is < 10000 then HRA=15% of basic & DA=45% of basic.If basic salary is >=10000 then HRA=20% of basic & DA=50% of basic.