DESHAW PROGRAMMING INTERVIEW Questions

DESHAW PROGRAMMING INTERVIEW QUESTIONS
1. To display the contents of a executable file the following
command can be used
(a) cat (b) od (c) vi (d) ed ans : b
2. Assume the current directory contains 10 files and does'nt
contain 'temp'. What will be the output of the follwing
commands?
$ls > temp
$wc -l temp
(a) 9 (b) 10 (c) 11 (d) undefined. ans : b *c
3. If one wants the output of one command( command1) to be
printed inthe printer as well as to be added to another file
(outfile) which one of the following is a currect command
he can give?
(a) $command1 >>outfile|tee lpr
(b) $tee -a command1 | lpr
(c) $ command1 | tee outfile | lpr
(d) $ command | tee -a outfile |lpr ans : d
(4) In the shell program set -x will cause
A. Execution of the commands in the background
B. Execution of the commands in verbose mode
C. Exit from the shell program.
D. Exit from the shell program after executing the next command
ans:b
(5) ACL in UNIX refers to
A. Acces Control List
B. Action Control List
C. Application Command Language
D. Advanced C lanuage
ans a:
(6) The command echo*
A. will print * on the screen
B. will print contents of all the files in the current
directory
C. will list the files in the current directory
D. will print the contents of all shell variables
ans c:
(7) ls || date will
A. print the name of the files in the current directory
B. print today's date and time
C. (A) followed by (B)
D. none of the above
ans : a
(8) The built-in shell variable $$ refers to
A. printing numbers in dollar format
B. proces id_ of last command
C. proces id_ of last background command issued
D. proces-id of current shell
ans :d
(9) dd is mainly used for
A. dealing with raw, unformated data, whatever the source
B. dealing with data dictionary
C. deleting a directory
D. none of the above
ans :d
(10) vis in UNIX is
A. a command that takes only one input
B. a command for deleting strange or unwanted charectors that
may have crept into files.
C. points non-printable characters in understandable format
D. all of the above
(11) Which of the following is true regarding the UNIX
(i) Multiuser Operating System
(ii)Multitasking Operating System
(iii) Real timing Operating System
A. i only B. i and ii only C. i and ii and iii only
D. i and ii
ans : a
(12) ln command is used to
A. link object codes into a executable code
B. give two names to the same file
C. set line numbers for the file
D. none of the above
ans : b
(13) nohup command is used for
A. protecting the execution of programmes from aborting when
hangup signal is received
B. changing the execution priority of the programes
C. not hanging up of the modem
D. disconnecting a node from the system
ans : a
(14) SCCS is a
A. Tool for maintaining large programmes in a production
environment
B. Communication Protocol
C. Shell Programming Language
D. String processing utility
ans : a
(15) Which one of the following is true as long as UNIX is
concerned
A. One can do programming in C only
B. It can support terminals capable of printing only uppercase
characters
C. The text files are sorted as it is in MS-DOS
D. None of the above
ans: d
(16) Inside vi editor to replace the string 10/$$/92 with
10/$$/92 globally the following command can be used
A. :1,$ s/\/10\/\$\/94/10\/\$\$\/92/g
B. :1,$ s/\/10\/\$\/94/10\/\$\/$92/
C. :s10/$$/92/10/$$/92/g
D. :1,$ s/\/10\/$\/94/10\/$$\/92/g
**** ans : d
(17) The ed command without any argument
A. will print the current working directory
B. will make the home directory as current directory
C. will ask for the directory to be used as the current
directory
D. will go to the previous directory
(18) nice command is used
A. to increase/decrease execution priority of a command
B. to compress a file
C. to run a programme at latter time
D. to set the key board responce slower
ans : a
(19) What will be the output of the following command sequence
$ x='I am x'
$sh
$echo $x
A. I am x B. Blank line C. x D. None of the above
ans :b
(20) The command tr a-z 0-9 < x
A. converts all the digits to lowercase alphabets
B. converts all the lowercase alphabets to digits
C. will give syntax error
D. none of the above
ans :d

No comments:

 
Top Blogs