HOME ASSIGNMENT OPERATING SYSTEM
Name: C. Lalramfakmawia BCA 3rd Semester Roll no.:4
To: Miss Sangsangi
Part A: Short Answer Questions
1. What is an Operating System? Give one example.
An Operating System (OS) is a system software that manages all hardware and
software resources of a computer. It provides a stable and consistent environment for
applications to run and allows users to interact with the system through a user
interface. The OS handles tasks like memory management, process scheduling,
input/output operations, and file management.
Example: Microsoft Windows.
2. List any three functions of an Operating System.
The three functions of an Operating System are:-
• Memory Management:
The OS keeps track of each byte in a computer’s memory and allocates memory to
different processes as needed. It also deallocates memory when it is no longer
required.
• Process Management:
It manages the creation, scheduling, and termination of processes. The OS ensures
that processes do not interfere with each other and that system resources are used
efficiently.
• File Management:
The OS manages files on storage devices, including reading, writing, organizing, and
securing data. It provides a way for users and programs to create, delete, and access
files easily.
3. What are two main services provided by the Operating System?
• Program Execution:
The operating system loads programs into memory and runs them. It manages the
execution of programs, including handling instructions, allocating resources, and
terminating them when they’re done.
• Input/Output Operations:
The OS manages all input and output devices such as the keyboard, mouse, printer,
and display. It allows programs to perform I/O operations without needing to know
the details of the hardware.
4. What is the role of a user interface in an OS?
The user interface in an operating system allows users to interact with the computer
system and its hardware. It provides a way to give commands and receive feedback.
There are two main types:
• Graphical User Interface (GUI): Uses windows, icons, and menus, making it user-
friendly (e.g., Windows, macOS).
• Command Line Interface (CLI): Uses typed commands, suitable for advanced users
(e.g., MS-DOS, Linux terminal).
5. How does the OS manage memory?
The Operating System manages memory through a process called memory
management, which ensures efficient use of the computer’s RAM. It performs the
following tasks:
• Allocation: The OS allocates memory to processes when they are started and ensures
that each process has enough memory to run properly.
• Tracking: It keeps track of which parts of memory are in use and by which process.
• Protection: The OS ensures that one process cannot access the memory of another
process, providing security and stability.
• Deallocation: When a process finishes, the OS frees up its memory for other
processes.
Part B: Match the Following
Type of OS Description (Match the latter)
A. Batch OS 3. Jobs are grouped and processed
B. Time-sharing OS 4. Many users get short CPU time slots
C. Personal Computer OS 2. Runs on desktops and laptops
D. Real-Time OS 1. Used in real-time applications
Part C: Fill in the Blanks
1. In a multiprogramming OS, several programs reside in memory simultaneously.
2. A multiprocessing operating system controls more than one processor.
3. Distributed OS manages multiple networked computers as one system.
4. An example of a real-time OS is VxWorks (or RTLinux / QNX – any is acceptable).
5. Batch OS requires no interaction during program execution.
Part D: Long Answer Questions
1. Explain any four functions of an Operating System in detail.
a. Process Management:
The OS is responsible for creating, scheduling, and terminating processes. It manages process
execution, handles multitasking, and ensures that processes don’t interfere with each other.
b. Memory Management:
It keeps track of every byte of memory in a system, allocates memory to processes when
needed, and frees it when not in use. It also protects the memory space of each process to
prevent conflicts.
c. File System Management:
The OS manages files on different storage devices. It handles the creation, deletion, reading,
and writing of files, and organizes them in a structured way using directories and file
systems.
d. Device Management:
It controls all input/output devices by using device drivers. The OS ensures that devices like
printers, keyboards, and disk drives are used efficiently and without conflicts.
2. Describe the concept of Time-Sharing Operating System with an example.
A Time-Sharing Operating System allows multiple users to use a computer system
interactively at the same time. It gives each user a small time slice or “quantum” of CPU
time. After each time slice, the OS quickly switches to the next user, giving the illusion that
all users are working simultaneously.
Example: UNIX is a time-sharing OS. Multiple users can log into the system and run
different tasks at the same time, each getting a fair share of CPU time.
3. What is a Real-Time Operating System (RTOS)? Explain its types with examples.
A Real-Time Operating System (RTOS) is designed to process data and events within a
guaranteed time frame. It is used in systems where timing is critical, like medical devices,
robotics, and air-traffic control.
Types of RTOS:
a. Hard Real-Time OS:
In this type, timing constraints are very strict. Even a small delay can cause system failure.
Example: Aircraft control systems, Pacemakers.
b. Soft Real-Time OS:
Here, deadlines are important but not absolutely critical. Occasional delays are tolerable.
Example: Streaming media applications, online transaction systems.
4. Compare Parallel OS and Distributed OS.
Feature Parallel OS Distributed OS
Uses multiple processors in one Manages a group of networked
Definition
system. computers.
Shared memory between
Memory Each system has its own memory.
processors.
Task Tasks are split among multiple Tasks are distributed across different
Execution CPUs. systems.
Windows Server with multiple
Example Apache Hadoop, Google File System.
CPUs.
Resource sharing and system
Goal Speed up computation.
coordination.
5. Write a short note on Multiprogramming and how it increases CPU efficiency.
Multiprogramming is a technique where multiple programs are loaded into memory and the
CPU executes them one by one. When one program waits (for input/output), the CPU
switches to another ready program. This ensures the CPU is never idle.
CPU Efficiency:
Instead of sitting idle during input/output operations, the CPU keeps working on other
programs. This increases overall system throughput and ensures better resource utilization.
Example: In a multiprogramming system, while one program is printing a document, the
CPU can process calculations for another program.