Lecturer in Computer Science (B-17) — 2023 · Solved Past Paper
Question 1 Computer Science
The value of an automatic variable in C/C++ that is declared but not initialized will be __________.
- A. 0
- B. -1
- C. Unpredictable ✓ Correct answer
- D. None of these
Why each option?
A. Wrong: an uninitialised automatic variable does not default to 0 (that is only true for static/global variables).
B. Wrong: there is no rule that an uninitialised automatic variable holds -1.
C. Correct: an automatic (local) variable declared but not initialised holds a garbage/indeterminate value, so its value is unpredictable.
D. Wrong: option C is correct.
Question 2 Computer Science
Which of the following memory must be refreshed many times per second?
- A. Static RAM
- B. Dynamic RAM ✓ Correct answer
- C. EPROM
- D. ROM
Why each option?
A. Wrong: static RAM holds its value as long as power is supplied; it needs no refresh.
B. Correct: DRAM stores each bit in a capacitor that leaks charge, so it must be refreshed many times per second.
C. Wrong: EPROM is non-volatile read-only memory; it needs no refresh.
D. Wrong: ROM is non-volatile; it needs no refresh.
Question 3 Computer Science
__________ interprets program instructions and initiates control operations.
- A. Input Unit
- B. Storage Unit
- C. ALU
- D. Control Unit ✓ Correct answer
Why each option?
A. Wrong: the input unit feeds data into the computer; it does not interpret instructions or initiate control operations.
B. Wrong: the storage unit holds data and instructions; it does not interpret them.
C. Wrong: the ALU performs arithmetic and logic operations; it does not interpret instructions or direct control.
D. Correct: the control unit interprets program instructions and initiates the control operations of the processor.
Question 4 Computer Science
The time required for the fetching and execution of one simple machine instruction is called?
- A. Delay Time
- B. CPU Cycle ✓ Correct answer
- C. Seek Time
- D. Real Time
Why each option?
A. Wrong: delay time is a general timing term, not the fetch-and-execute time of one instruction.
B. Correct: the time required for the fetching and execution of one simple machine instruction is one CPU cycle (CPU cycle time).
C. Wrong: seek time is the time a disk head takes to move to a track.
D. Wrong: real time is a mode of processing, not the fetch-and-execute time of one instruction.
Question 5 Computer Science
Functionality performed by a "constructor" is __________.
- A. Construct a new class
- B. Construct a new object
- C. Construct a new function
- D. Initialize Objects ✓ Correct answer
Why each option?
A. Wrong: a constructor does not create a class; a class is a type definition.
B. Wrong in the strict sense: memory allocation creates the object; the constructor's own function is to initialise the object once created.
C. Wrong: a constructor does not create a function.
D. Correct: the functionality performed by a constructor is to initialise the object's members when the object is created.
Question 6 Computer Science
A graphic representation of an Information System is called?
- A. Flow Chart
- B. Pictogram
- C. Data Flow Diagram ✓ Correct answer
- D. Histogram
Why each option?
A. Wrong: a flowchart is a graphic representation of a process or algorithm, not of an information system.
B. Wrong: a pictogram is a chart using pictures to represent data, not a representation of an information system.
C. Correct: a data flow diagram is a graphic representation of an information system, showing how data flows through processes.
D. Wrong: a histogram is a bar chart of a frequency distribution, not a representation of an information system.
Question 7 Computer Science
Pointers are useful in ________?
- A. Locating Area on Disk
- B. Pointing mistakes in input data
- C. Traversing Linked List ✓ Correct answer
- D. All of these
Why each option?
A. Wrong: pointers address memory, not disk areas.
B. Wrong: pointers do not point out mistakes in input data.
C. Correct: pointers are the links between nodes, and they are used to traverse a linked list.
D. Wrong: options A and B are not uses of pointers.
Question 8 Computer Science
Which of the following tool(s) is not used in modeling the new system?
- A. Decision Tables
- B. Data Dictionary
- C. Data Flow Diagrams
- D. All of these
Why each option fails
A. Cannot be excluded: decision tables ARE used in modelling a system.
B. Cannot be excluded: the data dictionary IS used in modelling a system.
C. Cannot be excluded: data flow diagrams ARE used in modelling a system.
D. Cannot be correct: it would mean all three tools are not used in modelling, which is false. The printed question has no correct option and is excluded as DEFECTIVE (decided by assistant under owner's 8 Nov delegation).
Question 9 Computer Science
Multiplexing technique used by AM and FM radios is _________.
- A. FDM ✓ Correct answer
- B. WDM
- C. TDM
- D. None of these
Why each option?
A. Correct: frequency division multiplexing is the analogue technique used by AM and FM radio — each station is given its own frequency band.
B. Wrong: wavelength division multiplexing is used in fibre optics, not in AM/FM radio.
C. Wrong: time division multiplexing is a digital technique; AM/FM radio is analogue.
D. Wrong: option A is correct.
Question 10 Computer Science
Which of the following is a form of DoS attack?
- A. Vulnerability attack
- B. Bandwidth Flooding
- C. Connection Flooding
- D. All of these ✓ Correct answer
Why each option?
A. True in isolation: exploiting a vulnerability to deny service is a form of DoS attack.
B. True in isolation: flooding the bandwidth is a form of DoS attack.
C. True in isolation: flooding connections (for example SYN flooding) is a form of DoS attack.
D. Correct: vulnerability attacks, bandwidth flooding and connection flooding are all forms of denial-of-service attack.
Question 11 Computer Science
Elapsed time between initiating a query and receiving a response is called ________.
- A. Response Time ✓ Correct answer
- B. Waiting Time
- C. Processing Time
- D. Turnaround Time
Why each option?
A. Correct: response time is the elapsed time between initiating a query and receiving a response (the interval between submitting a request and the first response).
B. Wrong: waiting time is the time a process spends waiting in a ready queue.
C. Wrong: processing time is the time spent actually processing, not the elapsed time to a response.
D. Wrong: turnaround time is the total time from submission of a job to its completion.
Question 12 Computer Science
Which of the following are never inherited?
- A. Public data members
- B. Constructor function ✓ Correct answer
- C. Void functions
- D. Overload + Operator
Why each option?
A. Wrong: public data members are inherited by a derived class.
B. Correct: a constructor is never inherited; a derived class can only call the base class constructor.
C. Wrong: void functions are inherited like any other member function.
D. Wrong: overloaded operators are inherited by a derived class.
Question 13 Computer Science
How many objects can be created from a abstract class?
- A. Zero ✓ Correct answer
- B. One
- C. Two
- D. As many as you want
Why each option?
A. Correct: an abstract class cannot be instantiated, so zero objects can be created from it (pointers and references to it are still allowed).
B. Wrong: not even one object can be created from an abstract class.
C. Wrong: no objects at all can be created from an abstract class.
D. Wrong: no objects at all can be created from an abstract class.
Question 14 Computer Science
In which of the storage placement strategies a program is placed in the largest available hole in the main memory
- A. Best-fit
- B. First-fit
- C. Next-fit
- D. Worst-fit ✓ Correct answer
Why each option?
A. Wrong: best-fit places a program in the smallest hole that fits it.
B. Wrong: first-fit places a program in the first hole large enough.
C. Wrong: next-fit places a program in the next hole large enough after the last allocation.
D. Correct: worst-fit places a program in the largest available hole in main memory.
Question 15 Computer Science
Bankers algorithm in Operating Systems is used for_____________.
- A. Deadlock prevention
- B. Deadlock avoidance ✓ Correct answer
- C. Deadlock recovery
- D. Mutual exclusion
Why each option?
A. Wrong: prevention avoids deadlock by imposing restrictions (such as denying one of the four conditions); the Banker's algorithm does something different.
B. Correct: the Banker's algorithm is a resource-allocation and deadlock-avoidance algorithm — it tests each request and grants it only if the system stays in a safe state.
C. Wrong: recovery is what happens after a deadlock has already occurred.
D. Wrong: mutual exclusion is one of the four conditions for deadlock, not what the Banker's algorithm does.
Question 16 Computer Science
Frames from one LAN can be transmitted to another LAN via __________.
- A. Router
- B. Bridge ✓ Correct answer
- C. Repeater
- D. Modem
Why each option?
A. Wrong: a router forwards packets between networks at the network layer; frames between LANs are handled by a bridge.
B. Correct: frames from one LAN can be transmitted to another LAN via a bridge, which forwards frames by MAC address.
C. Wrong: a repeater only regenerates signals within one LAN segment; it does not forward frames between LANs.
D. Wrong: a modem modulates/demodulates signals for transmission over telephone lines; it does not forward frames between LANs.
Question 17 Computer Science
Which transmission mode is used for data communication along telephone lines?
- A. Parallel
- B. Serial ✓ Correct answer
- C. Synchronous
- D. Asynchronous
Why each option?
A. Wrong: parallel transmission sends many bits at once over many wires; telephone lines have a single wire pair.
B. Correct: serial transmission sends one bit at a time, which suits the single wire pair of an ordinary telephone connection.
C. Wrong: synchronous is a timing mode of serial transmission, not the transmission mode itself.
D. Wrong: asynchronous is a timing mode of serial transmission, not the transmission mode itself.
Question 18 Computer Science
Which of the following device is used to connect to systems, especially if the systems have different protocols?
- A. Hub
- B. Bridge
- C. Gateway ✓ Correct answer
- D. Repeater
Why each option?
A. Wrong: a hub connects devices within one network; it does not translate between different protocols.
B. Wrong: a bridge connects similar LANs; it does not translate between different protocols.
C. Correct: a gateway is a network node that connects two networks with different transmission protocols.
D. Wrong: a repeater only regenerates signals; it does not connect systems with different protocols.
Question 19 Computer Science
The complexity of merge sort algorithm is ___________.
- A. 0(n)
- B. 0(log n)
- C. 0(n2)
- D. 0(n log n) ✓ Correct answer
Why each option?
A. Wrong: merge sort is not linear time (the option prints "0(n)" for O(n)).
B. Wrong: merge sort is not logarithmic time (the option prints "0(log n)" for O(log n)).
C. Wrong: merge sort is not quadratic time (the option prints "0(n2)" for O(n²)).
D. Correct: the time complexity of merge sort is O(n log n) (the option prints "0(n log n)").
Question 20 Computer Science
Twisted pair, coaxial and fiber optic cables are the example of ________ transmission medium.
- A. Guided ✓ Correct answer
- B. Unguided
- C. Dispersed
- D. None of these
Why each option?
A. Correct: twisted pair, coaxial and fibre optic cables are guided transmission media — the waves are guided along a physical path.
B. Wrong: unguided media are wireless (radio, microwave, infrared), not cables.
C. Wrong: "dispersed" is not a class of transmission medium.
D. Wrong: option A is correct.
Question 21 Computer Science
In OSI model, as a data packet moves from lower to upper layers, headers are _________.
- A. Added
- B. Removed ✓ Correct answer
- C. Rearranged
- D. None of these
Why each option?
A. Wrong: headers are added when data moves DOWN the layers (encapsulation at the sender), not up.
B. Correct: as a data packet moves from lower to upper layers, headers are removed (decapsulation at the receiver).
C. Wrong: headers are not rearranged on the way up the layers.
D. Wrong: option B is correct.
Question 22 Computer Science
The transfer of information from memory to outside environment is _________.
- A. Read operation ✓ Correct answer
- B. Write operation
- C. Transfer operation
- D. None of these
Why each option?
A. Correct: the transfer of information from memory to the outside environment is a read operation.
B. Wrong: a write operation transfers information INTO memory, the reverse direction.
C. Wrong: "transfer operation" is not the standard term for this.
D. Wrong: option A is correct.
Question 23 Computer Science
In operating system, each process has its own __________ .
- A. Open files
- B. Address space and global variables
- C. Pending alarms, signals and signal handlers
- D. All of these ✓ Correct answer
Why each option?
A. True in isolation: each process has its own list of open files.
B. True in isolation: each process has its own address space (code, data, stack, heap).
C. True in isolation: each process has its own pending alarms, signals and signal handlers.
D. Correct: each process has its own open files, address space and pending alarms/signals.
Question 24 Computer Science
The address of the next instruction to be executed by the current process is provided by the:
- A. CPU Registers
- B. Process stack
- C. Program Counter ✓ Correct answer
- D. Pipe
Why each option?
A. Wrong: CPU registers hold data and intermediate values, not the address of the next instruction.
B. Wrong: the process stack holds return addresses and local variables, not the address of the next instruction to execute.
C. Correct: the program counter holds the address of the next instruction to be executed, and is incremented after each instruction.
D. Wrong: a pipe is an inter-process communication channel, not a register holding the next instruction's address.
Question 25 Computer Science
A Relational Database consists of a collection of__________
- A. Tables ✓ Correct answer
- B. Fields
- C. Records
- D. Keys
Why each option?
A. Correct: a relational database consists of a collection of tables (relations) containing rows and columns.
B. Wrong: fields (columns) are parts of a table, not what a relational database consists of.
C. Wrong: records (rows) are parts of a table, not what a relational database consists of.
D. Wrong: keys identify records within a table; they are not what a relational database consists of.
Question 26 Computer Science
Database __________ which is the logical design of the database, and the database _______ which is a snapshot of the data in the database at a given instant in time.
- A. Instance, Schema
- B. Relation, Schema
- C. Relation, Domain
- D. Schema, Instance ✓ Correct answer
Why each option?
A. Wrong: the order is reversed — the logical design is the schema, the snapshot of the data is the instance.
B. Wrong: the logical design is the schema, not a relation, and the snapshot is the instance, not the schema.
C. Wrong: neither "relation" nor "domain" fits either blank.
D. Correct: the database schema is the logical design of the database, and the database instance is a snapshot of the data at a given instant in time.
Question 27 Computer Science
Default TCP port number for HTTP is ___________ .
- A. 65
- B. 75
- C. 85
- D. None of these ✓ Correct answer
Why each option?
A. Wrong: 65 is not the default HTTP port.
B. Wrong: 75 is not the default HTTP port.
C. Wrong: 85 is not the default HTTP port.
D. Correct: the default TCP port for HTTP is 80, which is not among the options.
Question 28 Computer Science
Multiplexing technique used for transmitting analog signals is _________.
- A. FDM & WDM ✓ Correct answer
- B. TDM & FDM
- C. WDM & TDM
- D. bytes
Why each option?
A. Correct: FDM (frequency division multiplexing) and WDM (wavelength division multiplexing) are the multiplexing techniques used for transmitting analogue signals.
B. Wrong: TDM (time division multiplexing) is a digital technique.
C. Wrong: TDM is a digital technique.
D. Wrong: "bytes" is not a multiplexing technique.
Question 29 Computer Science
An IPv4 address consists of:
- A. 4 bits
- B. 32 bits ✓ Correct answer
- C. 32 bytes
- D. 8 bytes
Why each option?
A. Wrong: an IPv4 address is far longer than 4 bits.
B. Correct: an IPv4 address consists of 32 bits (four 8-bit octets, written in dotted decimal notation).
C. Wrong: 32 bytes would be 256 bits.
D. Wrong: 8 bytes would be 64 bits.
Question 30 Computer Science
Encryption/ Decryption is performed by _________ layer of OSI.
- A. Application
- B. Session
- C. Presentation ✓ Correct answer
- D. Network
Why each option?
A. Wrong: the application layer provides services to the user, not encryption/decryption.
B. Wrong: the session layer manages sessions (dialog control), not encryption/decryption.
C. Correct: the presentation layer translates and formats data for the application layer, and handles encryption and decryption.
D. Wrong: the network layer handles routing, not encryption/decryption.
Question 31 Computer Science
In Operating Systems, absolute path starts from _________?
- A. Current Directory
- B. Root Directory ✓ Correct answer
- C. Present Directory
- D. None of these
Why each option?
A. Wrong: a path starting from the current directory is a relative path.
B. Correct: an absolute path specifies a file or directory location starting from the root directory.
C. Wrong: a path starting from the present (current) directory is a relative path.
D. Wrong: option B is correct.
Question 32 Computer Science
Semaphores are used to solve the problem of _________?
- A. Race condition
- B. Mutual exclusion
- C. Critical section ✓ Correct answer
- D. None of these
Why each option?
A. True in substance: semaphores prevent race conditions by controlling access to shared resources.
B. True in substance: semaphores provide mutual exclusion over a shared resource.
C. Picked: the canonical textbook key for this exact question is the critical section problem — semaphores are used to solve the critical-section problem in concurrent systems.
D. Wrong: options A, B and C are all what semaphores address. Picked by assistant under owner's 8 Nov delegation.
Question 33 Computer Science
Which of the following is a service not supported by Operating System?
- A. Protection
- B. Accounting
- C. Compilation ✓ Correct answer
- D. I/O operation
Why each option?
A. Wrong: protection IS a service supported by the operating system.
B. Wrong: accounting (tracking resource usage) IS a service supported by the operating system.
C. Correct: code compilation is done by a compiler, not by the operating system.
D. Wrong: I/O operations ARE a service supported by the operating system.
Question 34 Computer Science
The process of converting binary data into digital signals is called
- A. Line coding ✓ Correct answer
- B. Multiplexing
- C. De multiplexing
- D. I/O operation
Why each option?
A. Correct: line coding is the process of converting binary data (a sequence of bits) into digital signals.
B. Wrong: multiplexing combines multiple signals onto one channel; it does not convert binary data into digital signals.
C. Wrong: demultiplexing separates a combined signal back into its parts; it does not convert binary data into digital signals.
D. Wrong: an I/O operation is data transfer to or from a device, not the conversion of binary data into digital signals.
Question 35 Computer Science
Time required to send one single bit is called __________
- A. Bit rate
- B. Baud rate
- C. Bit interval ✓ Correct answer
- D. None of these
Why each option?
A. Wrong: bit rate is the number of bits transmitted per second, not the time to send one bit.
B. Wrong: baud rate is the number of signal changes per second, not the time to send one bit.
C. Correct: the bit interval is the time required to send one single bit.
D. Wrong: option C is correct.
Question 36 Computer Science
The loss of energy in a signal during transmission is called__________
- A. Distortion
- B. Attenuation ✓ Correct answer
- C. Amplification
- D. None of these
Why each option?
A. Wrong: distortion is a change in the shape of a signal, not a loss of its energy.
B. Correct: attenuation is the loss of energy (reduction in signal strength) during transmission.
C. Wrong: amplification increases signal strength — the opposite of a loss of energy.
D. Wrong: option B is correct.
Question 37 Computer Science
In Relational Databases, the tuples of the relations can be of__________ order.
- A. Any ✓ Correct answer
- B. Same
- C. Sorted
- D. Constant
Why each option?
A. Correct: in relational databases the tuples of a relation can be in any order — the order of the tuples does not matter.
B. Wrong: tuples need not be in the same order.
C. Wrong: tuples need not be sorted.
D. Wrong: tuple order is not constant.
Question 38 Computer Science
In case of Zero-address instruction method the operands are stored in ___________.
- A. Registers
- B. Accumulators
- C. Stack ✓ Correct answer
- D. Cache
Why each option?
A. Wrong: a zero-address instruction does not hold its operands in general registers.
B. Wrong: operands in an accumulator belong to one-address (accumulator) instructions, not zero-address instructions.
C. Correct: in the zero-address instruction method the operands are stored on the stack (the top of the stack is implied by the instruction).
D. Wrong: a cache is a fast memory, not where zero-address operands are stored.
Question 39 Computer Science
In Software Engineering which one of the following is not a phase of Prototyping Model?
- A. Quick Design
- B. Coding ✓ Correct answer
- C. Prototype Refinement
- D. Engineer Product
Why each option?
A. Wrong: quick design IS a phase of the prototyping model.
B. Correct: "coding" is not a named phase of the prototyping model — its phases are quick design, building the prototype, user evaluation, prototype refinement and engineering the product.
C. Wrong: prototype refinement IS a phase of the prototyping model.
D. Wrong: engineering the product IS a phase of the prototyping model.
Question 40 Computer Science
Rapid Application Development (RAD) Model has __________ phases.
- A. 2
- B. 3
- C. 4
- D. 5 ✓ Correct answer
Why each option?
A. Wrong: the RAD model has more than two phases.
B. Wrong: the RAD model has more than three phases.
C. Wrong: the RAD model has more than four phases.
D. Correct: the RAD model has five phases — business modelling, data modelling, process modelling, application generation, and testing and turnover.
Question 41 Computer Science
__________ Network extends a private network across public networks?
- A. Local Area
- B. Virtual Private ✓ Correct answer
- C. Enterprise Private
- D. Storage area
Why each option?
A. Wrong: a local area network covers a small area; it does not extend a private network across public networks.
B. Correct: a virtual private network (VPN) extends a private network across a public network such as the internet.
C. Wrong: "enterprise private" is not the network type that extends a private network across public networks.
D. Wrong: a storage area network connects storage devices; it does not extend a private network across public networks.
Question 42 Computer Science
Physical or logical arrangement of a network is _____________.
- A. Routing
- B. Networking
- C. Topology ✓ Correct answer
- D. None of these
Why each option?
A. Wrong: routing is the choice of a path for data, not the arrangement of a network.
B. Wrong: networking is the general practice of connecting computers, not the arrangement of a network.
C. Correct: the physical or logical arrangement of a network is its topology.
D. Wrong: option C is correct.
Question 43 Computer Science
____________ keyword is used to inherit a class in Java.
- A. Super
- B. Extends ✓ Correct answer
- C. This
- D. Implements
Why each option?
A. Wrong: super refers to the parent class's members, it is not the inheritance keyword.
B. Correct: in Java the extends keyword is used to inherit a class.
C. Wrong: this refers to the current object, it is not the inheritance keyword.
D. Wrong: implements is used to implement an interface, not to inherit a class.
Question 44 Computer Science
Which of these is supported by method overriding in Java?
- A. Abstraction
- B. Encapsulation
- C. Polymorphism ✓ Correct answer
- D. None of these
Why each option?
A. Wrong: abstraction is hiding complexity behind an interface; it is not what method overriding supports.
B. Wrong: encapsulation is bundling data and methods; it is not what method overriding supports.
C. Correct: runtime polymorphism is achieved through method overriding — a subclass method with the same name, parameters and return type as the parent's is chosen at run time.
D. Wrong: option C is correct.
Question 45 Computer Science
IPv6 does not use__________ type of address.
- A. Broadcast ✓ Correct answer
- B. Multicast
- C. Anycast
- D. None of these
Why each option?
A. Correct: IPv6 does not use broadcast addresses — there is no concept of a broadcast address in IPv6; it uses multicast and anycast instead.
B. Wrong: IPv6 DOES use multicast addresses.
C. Wrong: IPv6 DOES use anycast addresses.
D. Wrong: option A is correct.
