A directory of Objective Type Questions covering all the Computer Science subjects. Here you can access and discuss Multiple choice questions and answers for various compitative exams and interviews.

41. Which of the following set of Unix commands will always display “WELCOME” ?
a. export title=WELCOME; Echo $title
b. title = WELCOME; export $ title ; sh –c “echo $title”
c. title = WELCOME; export title ; sh –c “echo $title”
d. title = WELCOME; echo $title
View Answer Report Discuss Too Difficult! Search Google
Answer: (c).title = WELCOME; export title ; sh –c “echo $title”

42. Which of the following shell scripts will produce the output “my first script” ?
a. for i in my first script { echo –i $i}
b. for my first script; do echo –n; done
c. for i in my first script; do echo –i $i; done
d. for n in my first script; do echo –i $i; done
View Answer Report Discuss Too Difficult! Search Google
Answer: (c).for i in my first script; do echo –i $i; done

43. Which of the following statements is not true for UNIX Operating System ?
a. Major strength of UNIX Operating System is its open standards which enabled large number of organizations ranging from academicia to industries to participate in its development.
b. UNIX kernel uses modules with well specified interfaces and provides advantages like simplified testing and maintenance of kernel. It has better extensibility as the kernel is not monolithic.
c. UNIX is kernel based operating system with two main components viz. process management subsystem and file management subsystem.
d. All devices are represented as files which simplify the management of I/O devices and files. The directories structure used is directed acyclic graph.
View Answer Report Discuss Too Difficult! Search Google
Answer: (b).UNIX kernel uses modules with well specified interfaces and provides advantages like simplified testing and maintenance of kernel. It has better extensibility as the kernel is not monolithic.

44. Consider the following UNIX command:

sort < in > temp; head -30 < temp; rm temp

Which of the following functions shall be performed by this command?
a. Sort, taking the input from "temp", prints 30 lines from temp and delete the file temp
b. Sort the file "temp", removes 30 lines from temp and delete the file temp
c. Sort, taking the input from "in" and writing the output to "temp" then prints 30 lines from temp on terminal. Finally "temp" is removed
d. Sort, taking the input from 'temp" and then prints 30 lines from "temp" on terminal. Finally "temp" is removed
View Answer Report Discuss Too Difficult! Search Google
Answer: (c).Sort, taking the input from "in" and writing the output to "temp" then prints 30 lines from temp on terminal. Finally "temp" is removed

45. The mv command changes
a. the inode
b. the inode-number
c. the directory entry
d. both the directory entry and the inode
View Answer Report Discuss Too Difficult! Search Google
Answer: (c).the directory entry

46. A UNIX file system has 1 KB block size and 4-byte disk addresses. What is the maximum file size if the inode contains ten direct block entries, one single indirect block entry, one double indirect block entry and one triple indirect block entry?
a. 30 GB
b. 64 GB
c. 16 GB
d. 1 GB
View Answer Report Discuss Too Difficult! Search Google
Answer: (c).16 GB

47. A user level process in Unix traps the signal sent on a Ctrl + C input and has a signal handling routine that saves appropriate files before terminating the process. When a Ctrl + C input is given to this process, what is the mode in which the signal handling routine executes ?
a. User mode
b. Kernel mode
c. Superuser mode
d. Privileged mode
View Answer Report Discuss Too Difficult! Search Google
Answer: (b).Kernel mode

48. Which one of the following options is not a shell in UNIX system?
a. Bourne Shell
b. C Shell
c. Net Shell
d. Korn Shell
View Answer Report Discuss Too Difficult! Search Google
Answer: (c).Net Shell

49. Which command allows you to view your file 24 lines at a time ?
a. More
b. Cat
c. Pg
d. None of the above
View Answer Report Discuss Too Difficult! Search Google
Answer: (a).More

50. The Unix command used to find out the number of characters in a file is
a. nc
b. wc
c. chcnt
d. lc
View Answer Report Discuss Too Difficult! Search Google
Answer: (b).wc

Page 5 of 7