Unix

1:

A file x is created with the following contents
echo today is:
date

           If you type x.then

A. It echoes the message. followed by date.
B. It gives the desired output only if the execute permission of file x is set.
C. The desired output can be got by the command sh x. which works even if x has its execute permission not set.
D. Both (b) and (c)
 

Answer : D

Explanation :
When you create a file using an editor, it will be assigned default permission setting (determined by the umask value). Generally the execute permission will be off. So. to run a shell script, set its execute bit on. However, if you run sh x, x will be executed, even if its execute bit is off.

Write your comments here:


Report Error
 

Option: A

Explanation : Explanation will come here. Explanation will come here. Explanation will come here. Explanation will come here. Explanation will come here.