Answered>Order 2357

  1. [12] Give a command that will:
  2. Create the file “foo” if it does not exist, and create the file “foo.err” if creating “foo” fails. Ignore any further errors.
  3. Examine two files “foo” and “bar”, and delete whichever one of them is older. If they have the same age, delete one of them arbitrarily.
  4. Display a message if the file “foo” contains more lines than contained in the file “bar”. Otherwise display nothing.
  5. The programs “foo” and “bar” both produce a single line of output when run. Display “same” if the output from “foo” is the same as the output from “bar”. The outputs may contain spaces, but no other special characters. If they are different, display nothing.
 
"Not answered?"
Get the Answer