Operating systems exams - multiple choice questions (MCQ) and answers, Objective type questions, OS exam questions, MCQ in system programming
1. Translator for low level programming language were termed as
a) Compiler
b) Linker
c) Assembler
d) Loader
Answer: (c) Assembler An assembler is a type of computer program that interprets source code written in assembly language into machine language, code and instructions that can be executed by a computer.An assembler performs the following;
|
2. The translator which perform macro expansion is called a
a) Macro processor
b) Macro pre-processor
c) Micro pre-processor
d) Assembler
Answer: (b) Macro pre-processor An assembly language macro is a template whose format represents a pattern of 0 or more assembly language statements that might be common to multiple programs. For this purpose, a macro language is used to provide syntax for defining macros. Where a sequence of assembly language statements can be represented by a macro, a macro call is inserted into the assembly program source code where the assembly code would otherwise go. A macro facility is used to interpret macro definitions and expand each macro call as it occurs with the requisite pattern of assembly language statements, providing expanded source code ready for the assembler. Hence, the macro facility is a preprocessor, which interprets all macro calls into assembly code prior to passing the expanded code on to the assembler. A macro facility is an add-on piece of system software, a convenience for the programmer, to facilitate production of multiple lines of commonly occurring code via single macro calls embedded in the programmer's assembly program. [For
more information and examples, please refer here] |
3. Interval between the time of submission and completion of the job is called
a) Response time
b) Throughput
c) Turnaround time
d) Waiting time
Answer: (c) Turnaround time The interval from the time of submission of a process to the time of completion is the turnaround time. Turnaround time is the sum of the periods spent waiting to get into memory, waiting in the ready queue, executing on the CPU, and doing I/O. For example, let us assume that job A arrives at time 0 (submission time) and takes 6 time units to finish. Then the turnaround time of A is 6. |
4. The scheduling in which CPU is allocated to the process with least CPU burst time is called
a) Priority scheduling
b) Shortest Job First scheduling
c) Round Robin scheduling
d) First Come First Serve scheduling
Answer: (b) Shortest Job First (SJF) scheduling The idea behind the SJF algorithm is to pick the smallest fastest little job that needs to be done, get it out of the way first, and then pick the next smallest fastest job to do next. Technically this algorithm picks a process based on the next shortest CPU burst, not the overall process time. This scheduling algorithm associates with each process the length of its next CPU burst. SJF is optimal – gives minimum average waiting time for a given set of processes. Here, the difficulty is to find the length of the next CPU request. |
5. What does a time-sharing system need that a multi-programming system does not?
a) Trap mechanism
b) Kernel mode execution privileges
c) Shorter time slices
d) Interval Timer
Answer: (d) Interval Timer Time-sharing or multitasking is a logical extension of multiprogramming. The main difference between Multi programmed Batch Systems and Time-Sharing Systems is that in case of Multi programmed batch systems, objective is to maximize processor use, whereas in Time-Sharing Systems objective is to minimize response time. Time sharing system Time sharing is a technique that enables multiple users simultaneously accesses the system through terminals, with the OS interleaving the execution of each user program in a short burst or quantum of computation. Processor's time which is shared among multiple users simultaneously is termed as time-sharing. The time sharing operating system assures that all the tasks get to access the CPU one by one and for a fixed small interval of time. This interval is known as the time quantum. |
Related links:
OS Interview questions with answers
solved Interview questions in operating systems
GATE questions in system programming and operating systems
MCQ Interview questions in OS
Operating systems interview questions for competitive exams
objective type OS questions for IIT JEE entrance exam
No comments:
Post a Comment