Classical

Unix - Filters and Commands

6:  

The permission bits of a file noname. can be set to _rws_  _x_  _x  by the command.

A. chmod 711 noname
B. chmod go -rw noname
C. chmod 2711 noname
D. None of the above
 
 

Option: D

Explanation :
We can use the command chmod 711 noname, followed by chmod u+s noname (use
ls -1 noname and check). Else use the single command chmod 4711 noname. What is this "s" anyway? Only the super user has the permission to change /etc/ passwd file. But any user can update it through the passwd (bin/passwd) command. If you type ls-l /bin/passwd you can see the user execution bit set to s instead of x). It is because of this "s". a user can access /etc/passwd through the passwd command, for which he is not otherwise entitled to


7:  

 /bin/passwd has the user execution permission set to 's' because

A. This facility assigns to the user, permissions of the program owner. temporarily
B. It should allow users who don't have write permission to /etc/passwd to write to it
C. /etc/passwd is write protected
D. All of these
 
 

Option: D

Explanation :


8:  

If one doesn't want anyone else to read or write to a file named datfile, except through a program in a file filex , then he may use

A. chmod u+s filex ; chmod go_rw datfile
B. chmod 4711 filex ; chmod go_rw datfile
C. chmod 4711 datfile ; chmod go_rw filex
D. Both (a) and (b)
 
 

Option: D

Explanation :


9:  

Writing a C program that accepts input from keyboard, rather than from a file is advantageous because

A. Keyboard is a file that is already open
B. It can be used in a pipe, if it writes to stdout
C. Both (a) and (b)
D. None of the above
 
 

Option: C

Explanation :


10:  

Consider the following command that invokes the executable file a.out, with the following command line arguments a .out God loves you
argv( [1][2] )corresponds to the character

A. e
B. o
C. y
D. d
 
 

Option: D

Explanation :
argv [0] is a pointer to the command (here a.out) and argv [1] to the first argument.So, argv [1][2], refers to the third (since count begins at 0) character of the first argument which is d.




Suggest an improvement

 


Syllabus covered in this section is-

  • The UNIX System: File system, process management.
  •  Bourne shell, shell variables, command line programming
  •  Filters and Commands: Pr. Head, tail, cut. Paste. Sort. uniq, tr, join, etc, grep, egrep, fgrep, etc, sed, awk, etc.
  • System Calls (like) : Create, open. Close, read, write, iseek, link, unlink, stat, fstat, umask, chmod, exec, fork, wait, system.
  • Unix :Operating System
  •  Structure of Unix Operating System
  • UNIX Commands. Interfacing with Unix
  •  Editors and Compilers for Unix LEX  and YACC
  •  File system, System calls.
  • Filters, Shell programming

This Section covers Unix Questions Answers .These questions can be used for the preparation of various competitive and academic exams like

  • UGC NET Computer Science
  • Pre PhD Entrance Exam
  • DOEACC Exams
  • Kendriya Vidyalaya Sangathan Entrance Exam
  • Undergraduate Computer Science Examinations
  • Post Graduate Computer Science Test
  •  PhD Entrance Exam
  • Computer Engineering
  • National Eligibility Test (NET)
  • State Eligibility Test (SET)

Who can benefit

  • Unix Objective Questions Answers can be used by any student who is preparing for PhD entrance exam, pre PhD entrance exam, entrance exam or any other such exam.
  • Any student who is preparing for DOEACC exams can also use UNIX questions answers for preparation of his exams.
  • Unix  mcq can be useful for the students who are pursuing any undergraduate or post graduate degree in computer science like BE, ME , Btech, Mtech, .BSc, MSc, BCA, MCA, BS, MS  or any other such degree
  • UNIX mcq with answers and explanation can also be useful for the students who are preparing for any competitive exam or recruitment exams like UGC NET Computer Science, Kendriya Vidyalaya Sangathan PGT exam, PSU, IES or any other such exam.
  • Unix Operating System is an Elective subject for UGC NET Computer Science.
  • UNIX multiple choice questions answers can also be used by any candidate who wants to gain credits in UNIX in BS Computer science or MS Computer science.
  • UNIX mcq questions answers can be used for the preparation of National Eligibility Test (NET) and State Eligibility Test (SET).
  • You can download UNIX mcq pdf from this site.
  • You can also get access to UNIX multiple choice questions answers EBook.

Various Search Terms Used For This Section Are

  • Unix Quiz Questions With Answers

  • Unix Exam Questions Answers

  • Unix Mcq Questions Answers

  • Unix Mcq Pdf Download