Write a script that takes the name of a directory as an argument and searches the file hierarchy rooted at that directory for zero-length files. Write the names of all zero-length files to standard output. If there is no option on the command line, have the script delete the file after displaying its name, asking the user for confirmation, and receiving positive confirmation. A –f (force) option on the command line indicates that the script should display the filename but not ask for confirmation before deleting the file.

What will be an ideal response?

The following script segment deletes only ordinary files, not directories. As

always, you must specify a shell and check the arguments.



Computer Science & Information Technology

You might also like to view...

When entering data into a table, pressing the ________ key(s) moves to the next field

A) Ctrl and Tab B) Shift and Tab C) Tab D) Alt and Tab

Computer Science & Information Technology

When you send personalized e-mail messages to your Outlook contacts, you have to perform the merge in Outlook.

Answer the following statement true (T) or false (F)

Computer Science & Information Technology