PPSC Computer Science Book - Sample
PPSC Computer Science Book - Sample
Updated
MK Edition!
Edition!
Computer
Computer
Lecturer Guide
Lecturer Guide
PPSC | FPSC | SPSC | BPSC | AJKPSC | KPPSC
According to the Latest Syllabus & Pattern of All Public Service Commission Exams
Premium Features:
To The Point
To The Point Topic
Topic Wise
Wise Notes
Notes
Authentic, Concise, Error
Authentic, Concise, Error less
less && Result
Result
Oriented Notes
Oriented Notes + + One
One Liners
Liners +
+ Practice
Practice
MCQs
MCQs
Solved Past
Solved Past Papers
Papers && Most
Most Repeated
Repeated
Important MCQs
Important MCQs
According to
According to All
All Public
Public Service
Service
Commissions Syllabus
Commissions Syllabus
100% Success
100% Success Guaranteed
Guaranteed BY
BY
K. A.
K. A. USAMA
USAMA
MK PUBLICATIONS For Online Order:
LET'S MAKE IT HAPPEN! 0348-4233593
0348-4233593
Contact: 0342-4470091 | 0333-2605045
Email: mkpreparations@[Link] @MK PREPARATIONS
MK PREPARATIONS
Table of Content
• Introduction To Computing • Programing Fundamentals
& ICT & Core Concepts
• History Of Computers • Programing In Core
• Computer System: Concepts (C, C++)
Architecture & Components • Web Development & Web
• Number Systems, Digital Programing
Logics & Data • Data Base And Data
• Operating Systems Management (DBMS)
P artificial domains. Understanding a system's structure allows for better design, management, and
optimization across fields like engineering, biology, and computing.
A system is described by four fundamental concepts:
R 1. Objective/Purpose: The primary goal the system is designed to achieve.
2. Components: The essential building blocks or parts that constitute the system.
E 3.
4.
Environment: Everything external to the system that interacts with or influences it.
Communication/Interaction: The mechanisms through which components and the system itself
P exchange information and coordinate their functions.
Types of Systems
A Systems are broadly categorized into two main types:
1.3.1 Natural Systems
R These occur organically in nature without human intervention. They are characterized by self-
regulation, adaptability, stability, and are governed by natural laws (physics, chemistry, biology).
A •
They are highly intricate and interdependent.
Examples: Ecosystems (forests, oceans), weather patterns, the solar system, the human body
T (circulatory, nervous systems), DNA, psychological systems (thoughts, emotions).
1.3.2 Artificial Systems
I These are intentionally designed and built by humans to fulfill specific needs or solve problems. They
are structured, require maintenance, and operate under predefined human-set rules and protocols.
O
• Examples:
o Knowledge Systems: Mathematics, logic, databases, information management systems.
o Engineering Systems: Civil (bridges, roads), mechanical (robotic arms), chemical (water treatment
N plants), electrical (home automation), software (library management systems).
o Social Systems: Academic institutions, governments, corporations.
S o Computer Systems: The primary focus of this chapter.
Key Differences:
Feature Natural Systems Artificial Systems
Origin Occur naturally. Designed and built by humans.
P a g e 1 | 26
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Complexity Highly intricate and Structured and relatively simpler.
interdependent.
Energy Source Natural (sunlight, water flow). Artificial (electricity, fuel).
P a g e 2 | 26
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
• Motherboard: The main circuit board that connects and allows communication between all
components (CPU, RAM, storage, ports).
• Central Processing Unit (CPU)/Microprocessor: The "brain" of the computer. It fetches, decodes,
and executes instructions from memory.
o Control Unit (CU): Directs and coordinates operations within the processor and manages the flow of
A • Solid State Drive (SSD): Chip-based storage using flash memory. Much faster, more durable, silent,
and energy-efficient than HDDs, but typically more expensive per gigabyte.
Optical Discs: CDs, DVDs, and Blu-ray discs that use lasers to read and write data.
R
•
• USB Flash Drive: Portable, rewritable chip-based storage.
• Memory Cards (SD Cards): Portable storage used in cameras, phones, and other devices.
A Output Devices
Hardware used to present processed data (information) to the user.
T • Monitor/Visual Display Unit (VDU): Displays text, graphics, and video (soft copy). Types: CRT
(older, bulky), LCD, LED (modern, flat-panel).
I • Printer: Produces physical hard copies. Types: Impact (e.g., dot-matrix) and Non-Impact (e.g.,
inkjet, laser).
O •
•
Plotter: Used for printing large-scale graphics like engineering drawings and architectural blueprints.
Speakers/Headphones: Output audio.
Multimedia Projector: Projects the computer's display onto a larger surface like a wall or screen.
N
•
Ports, Expansion Slots, and Cards
• Ports: Interfaces on the system unit for connecting peripheral devices (e.g., USB, HDMI, Ethernet,
S •
audio jacks, VGA).
Expansion Slots: Sockets on the motherboard (e.g., PCI, PCI Express) where expansion cards can be
inserted to add new capabilities.
• Expansion Cards: Circuit boards that add new functions (e.g., graphics card for enhanced video,
sound card for improved audio, network interface card for networking).
P a g e 3 | 26
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
• Biometric Systems: Use unique biological traits for identification and authentication (e.g.,
fingerprint scanners, facial recognition, iris scanners).
K Number Systems
A number system defines a set of values and rules used to represent quantity. The four primary
systems in computing are:
R Decimal 10 0, 1, 2, 3, 4, 5, 6, 7, 8, 9
Human-centric counting and
math.
E Fundamental representation
Binary 2 0, 1
P inside all computers.
Compact representation of
A Octal 8 0, 1, 2, 3, 4, 5, 6, 7
binary (historically significant).
R 0-9, A(10), B(11), Compact representation of
Hexadecimal 16 C(12), D(13), E(14), binary; used for memory
A F(15) addresses, color codes.
T •
All are positional-value systems: the value of a digit depends on its position.
Most Significant Digit (MSD): Leftmost digit (carries the most weight).
I • Least Significant Digit (LSD): Rightmost digit (carries the least weight).
Number System Conversions
O A. Conversion to Decimal (from any base): Multiply each digit by the base raised to its positional
power (starting at 0 for the LSD) and sum the results.
N •
•
Binary to Decimal: (1011.101)₂ = 1×2³ + 0×2² + 1×2¹ + 1×2⁰ + 1×2⁻¹ + 0×2⁻² + 1×2⁻³ = (11.625)₁₀
Hexadecimal to Decimal: (3AF)₁₆ = 3×16² + 10×16¹ + 15×16⁰ = (943)₁₀
S •
B. Conversion from Decimal (to any base):
For the integer part: Repeatedly divide by the target base and record remainders in reverse order.
• For the fractional part: Repeatedly multiply by the target base and record the integer parts
in forward order.
C. Direct Conversions Between Binary, Octal, and Hexadecimal: (Efficient because bases are
powers of 2).
• Binary ↔ Octal: Group binary digits into sets of 3 (from the binary point outward), pad if necessary,
then convert each group to its octal digit (0-7).
P a g e 7 | 26
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Examples Human voice, analog radio, vinyl MP3 files, digital TV, data in
records. computer memory.
11.2 Logic Gates
K 01|0
10|0
are 1.
11|1
P OR F=A+B 00|0
01|1
Output is 1 if AT LEAST ONE
input is 1.
R 10|1
E 11|1
NOT F = Ā (or A') 0|1 Output is the inverse
P 1|0 (complement) of the input.
A 11|0
NOR F = A+B‾A+B 00|1 Output is 1 only if ALL inputs
T 01|0 are 0 (OR + NOT).
I 10|0
11|0
O XOR F=A⊕B 00|0 Output is 1 only if inputs are
N 01|1 DIFFERENT.
10|1
S 11|0
Boolean Algebra and Simplification
• Boolean Algebra: A mathematical system for logic operations using variables that can be true (1) or
false (0) and operators (AND, OR, NOT).
• Truth Table: Lists all possible input combinations and their corresponding output for a Boolean
function or logic circuit.
P a g e 12 | 26
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
One Liners: Introduction to Computing and ICT
1. ICT is an umbrella term for computing tools enabling interaction in the digital world, representing
the convergence of telephone and computer networks.
2. A system is a collection of interconnected components working cohesively to achieve a specific
K 6. Natural systems are governed by natural laws, while artificial systems operate under human-
defined rules and protocols.
7. Design Science focuses on creating new artificial systems, like conservation software, to solve
problems.
8. A computer is a programmable electronic device that accepts input, processes it according to
P 9.
stored instructions, produces output, and stores results.
The primary objectives of a computer system are to perform computations, process data, and
R 10.
execute tasks efficiently to provide useful information.
An input device allows users to enter data and instructions into a computer, such as a keyboard,
E 11.
mouse, or scanner.
The standard keyboard layout is QWERTY.
P 12.
13.
A touch screen serves as both an input (touch) and output (display) device.
The system unit houses the primary electronic components of a computer, including the
motherboard and CPU.
A 14. The motherboard is the main circuit board connecting all components like the CPU, RAM,
storage, and ports.
R 15. The CPU, or microprocessor, is the computer's "brain," responsible for fetching, decoding, and
executing instructions.
A 16. The Control Unit (CU) directs and coordinates operations within the processor and manages data
flow.
T 17. The Arithmetic Logic Unit (ALU) performs all mathematical calculations and logical
comparisons.
I 18. Registers are high-speed temporary storage locations within the CPU for data and addresses being
processed.
19. The Memory Address Register (MAR) holds the memory location of data to be fetched or stored.
O 20. The Memory Data Register (MDR) holds the data fetched from or to be written to memory.
21. The Program Counter (PC) holds the address of the next instruction to be executed.
N 22. The Current Instruction Register (CIR) holds the instruction currently being decoded and
executed.
S 23. Random Access Memory (RAM) is volatile, read/write memory that temporarily holds the OS,
applications, and data in use.
24. Read-Only Memory (ROM) is non-volatile memory storing permanent, essential instructions like
the BIOS.
25. Cache memory is extremely fast memory located close to the CPU to store frequently used data
and speed up processing.
26. Secondary storage devices provide non-volatile, long-term retention of data, programs, and
information.
P a g e 15 | 26
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
27. Hard Disk Drives (HDD) use magnetic storage on spinning platters, offering large capacity at
lower cost but are slower than SSDs.
28. Solid State Drives (SSD) use chip-based flash memory, offering faster speeds, durability, and
energy efficiency than HDDs.
29. Output devices present processed data to the user, such as monitors (soft copy) and printers (hard
A 44.
system transferring both instructions and data.
A security risk in the Von Neumann architecture is that instructions and data share the same
memory, allowing a program to accidentally or maliciously modify other instructions.
R 45. Software is a set of instructions, data, or programs that tell computer hardware how to function and
perform tasks.
A 46. System software manages and controls hardware, providing a stable platform for application
software.
T 47. The Operating System (OS) manages hardware resources, provides user interfaces, runs
applications, and handles file and memory management.
I 48. Device drivers are specialized programs enabling the OS to communicate with and control specific
hardware devices.
O 49. Utility programs perform maintenance tasks like antivirus scanning, disk cleanup, and file
compression.
50. A compiler translates an entire high-level program into machine code at once, producing an
N independent executable file.
51. An interpreter translates and executes source code line-by-line, without producing a separate
S 52.
executable.
An assembler translates assembly language (low-level symbolic code) into machine code.
53. Application software helps end-users perform specific tasks, such as using a word processor or
spreadsheet.
54. Open Source Software has its source code made freely available for use, study, modification, and
distribution (e.g., Linux).
55. Freeware is copyrighted software distributed free of charge, but its source code is typically not
modifiable (e.g., Adobe Reader).
P a g e 16 | 26
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Practice MCQs
1. In the context of systems, which of the Answer: c) Instructions and data residing
following is NOT one of the four in the same memory space
fundamental concepts that describe any 6. Which of the following best distinguishes
P a) It is decremented
b) It is loaded with the address of the
a) Open Source Software
b) Shareware
fetched instruction c) Freeware
A c) It is incremented d) Firmware
d) It is compared with the CIR Answer: c) Freeware
R Answer: c) It is incremented
4. Which component of the CPU is
8. The technological shift from vacuum
tubes to transistors primarily characterized
A specifically responsible for performing all
mathematical calculations and logical
which generation of computers?
a) First to Second
T comparisons?
a) Control Unit (CU)
b) Second to Third
c) Third to Fourth
A a) 48
b) 65
a) Simplex
b) Half-Duplex
c) 97 c) Full-Duplex
R d) 32 d) Multiplex
Answer: b) 65 Answer: b) Half-Duplex
A 14. Which Unicode encoding form is
variable-length (1-4 bytes), backward
19. What is the key functional difference
between a network hub and a network
T compatible with ASCII, and the most
common on the web?
switch?
a) A hub operates at the network layer,
I a) UTF-16
b) UTF-32
while a switch operates at the data link
layer.
O c) UTF-8
d) ASCII-8
b) A hub broadcasts data to all connected
devices, while a switch directs data only to
Answer: c) UTF-8 the specific destination device.
N 15. In process management, what is a c) A switch connects different networks,
'thread'? while a hub connects devices within the
S a) A complete, independent program in
execution
same network.
d) A hub has more ports than a switch.
b) A high-priority system process Answer: b) A hub broadcasts data to all
c) A lightweight unit of execution within a connected devices, while a switch directs
process that shares resources data only to the specific destination
d) The state of a process when it is waiting device.
for an I/O operation 20. Which network topology connects every
device to every other device, providing
P a g e 23 | 26
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Chapter 2
History of Computers
2. History of Computers
Introduction to Computers:
The word 'computer' originally referred to people who performed mathematical calculations. Before
modern computers existed, these human 'computers' were employed to carry out complex arithmetic
operations, often used in fields like astronomy, engineering, and navigation. This practice dates back to at
least the 17th century.
M The first recorded use of the word 'computer' in English was in 1613, describing a person who computes.
Over the centuries, as technology progressed, mechanical and electronic devices took over the
K computational role. This evolution marked the transition from manual computing to the automated systems
we rely on today.
Understanding the history of computing helps us appreciate the innovations and challenges faced by early
scientists and inventors who laid the foundation for today’s digital age.
P The Mechanical Era (1600–1900)
R During the Mechanical Era, inventors developed physical devices to assist in computation. These devices
worked without electricity and were typically operated by hand.
E Tally Sticks
Tally sticks were simple tools used since ancient times to record numbers, debts, or messages. They were
P not calculators but rather record-keeping aids. A notch on a stick represented a unit of value or count. These
were used extensively in medieval Europe, especially for tax collection.
A Abacus (c. 2400 BC)
R The abacus is one of the oldest calculating tools known to humanity. First used in Babylon around 2400
BC and later perfected in China around 500 BC, the abacus consists of beads that can be moved along rods
A to perform arithmetic operations. It was especially useful in trading and finance and is still used today in
parts of Asia.
T Napier’s Bones (1614)
Invented by Scottish mathematician John Napier, this device used rods inscribed with numbers to perform
I multiplication and division. It simplified large calculations and was a precursor to the logarithmic slide rule.
Slide Rule (1622)
O Developed by William Oughtred, the slide rule expanded on Napier's work by using logarithmic scales. It
N was used primarily for complex calculations like roots, trigonometry, and logarithms, especially by
engineers until the 1970s.
S Pascaline (1642)
Created by French philosopher Blaise Pascal to help his father with tax collection, the Pascaline was a
mechanical calculator that could add and subtract. It used a series of rotating wheels and was limited in
functionality, but it marked a major step in the automation of arithmetic.
P a g e 1 | 19
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
One Liners: History of Computer
2. History of Computers
1. The word 'computer' originally referred to a person who performed mathematical calculations.
2. The first recorded use of the word 'computer' in English was in 1613.
3. The Mechanical Era of computing (1600-1900) involved physical devices operated without
electricity.
4. Tally sticks were ancient record-keeping aids, not calculators, often used in medieval Europe for
tax collection.
M 5. The abacus, dating to 2400 BC in Babylon, is one of the oldest calculating tools, using beads on
rods.
K 6. Napier's Bones (1614), invented by John Napier, used inscribed rods to simplify multiplication and
division.
7. The slide rule (1622), developed by William Oughtred, used logarithmic scales for complex
calculations.
8. The Pascaline (1642) was a mechanical calculator created by Blaise Pascal to perform addition and
P subtraction.
9. Gottfried Wilhelm Leibniz designed the Stepped Reckoner (1672), capable of all four basic
R arithmetic operations.
10. The Arithmometer (1820) by Charles Xavier Thomas de Colmar was the first commercially
E successful mechanical calculator.
11. Charles Babbage, the Father of the Computer, proposed the Difference Engine and Analytical
P Engine.
12. The Difference Engine was designed to compute polynomial functions and print results
A automatically.
13. The Analytical Engine is considered the first design for a general-purpose mechanical computer.
14. Ada Lovelace wrote the first algorithm intended for the Analytical Engine, making her the first
R programmer.
15. Ada Lovelace suggested using binary and conceptualized machine-generated music.
A 16. The Scheutzian Engine (1843) was the first mechanical calculator to automatically print its results.
17. The Jacquard Loom (1881) used punch cards to control weaving patterns, inspiring future
T computer data input.
18. Herman Hollerith's Tabulating Machine (1890) used punched cards for data processing, starting
I with the U.S. Census.
19. The Tabulating Machine's innovation led to the founding of IBM.
O
20. The Electronic Era brought faster, smaller, more reliable machines using electricity and introduced
programmability.
21. Konrad Zuse's Z1 (1936-1938) is considered the first freely programmable mechanical computer.
N 22. The Z1 used binary floating-point arithmetic and input via punched tape.
23. The Atanasoff-Berry Computer (ABC) (1939-1942) was the first electronic digital computer.
S 24. The ABC used binary representation and vacuum tubes to solve systems of linear equations.
25. The Harvard Mark I (1943), or IBM ASCC, was an electromechanical computer over 51 feet long.
26. The Harvard Mark I was used by the U.S. Navy for ballistics calculations during WWII.
27. ENIAC (1946) was the first general-purpose electronic digital computer, containing over 17,000
vacuum tubes.
28. Programming ENIAC required manual reconfiguration using wires and switches.
29. EDVAC (1952), proposed by John von Neumann, introduced the stored-program architecture.
P a g e 10 | 19
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Practice MCQs
2. History of Computers
1. What was the original meaning of the word computer
"computer"? d) First commercial computer
a) An electronic calculating device Answer: c) First freely programmable
b) A person who performs mathematical mechanical computer
calculations 7. The Atanasoff-Berry Computer (ABC)
c) A mechanical automation tool introduced which of the following concepts?
M d) A data storage unit
Answer: b) A person who performs
a) Stored-program architecture
b) Use of transistors
K mathematical calculations
2. The Pascaline, invented by Blaise Pascal, was
c) Binary representation and electronic
calculation using vacuum tubes
primarily designed to: d) Integrated circuits
a) Perform multiplication and division Answer: c) Binary representation and
b) Weave complex fabric patterns electronic calculation using vacuum tubes
P c) Assist with tax collection through addition 8. What was the primary use of the Harvard Mark I
and subtraction during World War II?
R d) Solve polynomial equations
Answer: c) Assist with tax collection through
a) Code-breaking
b) Ballistics calculations for the U.S. Navy
E addition and subtraction
3. Which device is considered the first design for a
c) Predicting election results
d) Running business payroll
P general-purpose mechanical computer?
a) Difference Engine
Answer: b) Ballistics calculations for the U.S.
Navy
A b) Analytical Engine
c) Stepped Reckoner
9. ENIAC differed from earlier computers
primarily because it was:
d) Arithmometer a) The first mechanical computer
R Answer: b) Analytical Engine b) The first general-purpose electronic digital
4. Ada Lovelace is historically significant for: computer
A a) Inventing the first mechanical calculator
b) Writing the first algorithm intended for
c) The first to use punch cards
d) The first portable computer
T machine processing
c) Developing the stored-program concept
Answer: b) The first general-purpose
electronic digital computer
I d) Building the first electronic computer
Answer: b) Writing the first algorithm
10. The key architectural concept proposed by John
von Neumann and implemented in EDVAC was:
O
intended for machine processing a) The use of vacuum tubes
5. The Tabulating Machine, which used punched b) Parallel processing
cards for data processing, directly led to the c) The stored-program architecture
N founding of which company? d) Binary logic gates
a) Microsoft Answer: c) The stored-program architecture
S b) IBM
c) Intel
11. UNIVAC I holds the distinction of being the:
a) First computer to use a graphical user
d) Apple interface
Answer: b) IBM b) First commercially sold computer
6. Konrad Zuse's Z1 is notable for being the: c) First computer to connect to the internet
a) First electronic digital computer d) First portable computer
b) First computer to use vacuum tubes Answer: b) First commercially sold computer
c) First freely programmable mechanical
P a g e 15 | 19
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Chapter 3
Computer System: Architecture and Components
Introduction To Computer And Its Basic Operations
In today's information age, computers are used in every walk of life. They are found in devices ranging
Definition of a Computer
M A computer is an electronic device that accepts input data and instructions via input devices, stores
them until needed, processes the data, and produces output through output devices.
K Basic Operations of a Computer
All computers perform four fundamental operations to carry out any task: Input, Processing, Output,
and Storage.
P • Input Operation: The process of capturing or accepting data or information using input devices (e.g.,
keyboard, mouse).
R • Processing Operation: The transformation of input into output. The Central Processing Unit
(CPU) performs this task under the direction of a program.
• Output Operation: The result or outcome of the processing, delivered via output devices (e.g.,
E monitor, printer, speakers).
• Storage Operation: The process of retaining data, information, or instructions so the user can retrieve
P them when required. Storage can be temporary (e.g., RAM) or permanent (e.g., Hard Disk).
R
addition to managing complex systems.
• Early Computing Devices:
o Abacus (c. 3000 BC): Considered the first computer, using a system of sliding beads for calculations.
A o Leibniz's Calculating Machine (1694): A mechanical device that could add, subtract, and multiply
using gears and dials.
T o
o
Difference Engine (1822): Proposed by Charles Babbage to solve differential equations.
Analytical Engine: Babbage's later concept for a general-purpose computer.
I o Tabulating Machine (1889): Developed by Herman Hollerith for the U.S. census, using punched
cards.
O o
o
Z3 (1941): Developed by Konrad Zuse, used for designing airplanes and missiles.
Harvard Mark I (1944): An electromechanical relay computer.
ENIAC (1946): The first general-purpose electronic computer, significantly faster than its
N
o
predecessors.
o EDVAC (1945): Designed by John von Neumann, it introduced the stored-program concept.
S o UNIVAC-I (1951): One of the first commercially available computers.
• Modern Computing Devices: Include personal computers, laptops, tablets, smartphones, and
embedded systems in various appliances and vehicles.
P a g e 1 | 20
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
CLASSIFICATION OF COMPUTERS
Computers are classified based on size, performance, and application areas.
K Computers)
users. Now powerful enough for
business networks.
work, home, school. Portable,
lightweight, often battery-
powered.
P High-speed processing
(Billions of Instructions Per
R Second most powerful and Second - BIPS). Supports
E Mainframe
Computers
expensive. Used by large
organizations for critical, bulk-
many terminals
simultaneously. Used for
P data processing. census, ERP, financial
A transactions, airline
reservations, ATMs.
R Extremely high speed
N Includes laptops,
Devices enabling mobile smartphones, tablets, PDAs.
S Mobile Computers computing—processing and Feature wireless connectivity
transmitting data wirelessly. (full-duplex), portability, and
mobile-specific software.
M 5. Output operation delivers the result or outcome of processing via devices like a monitor, printer, or
speakers.
6. Storage operation retains data, instructions, or information for future retrieval, and can be temporary
K (RAM) or permanent (Hard Disk).
7. The Abacus (c. 3000 BC) is considered the first computing device, using sliding beads for
calculations.
8. Charles Babbage proposed the Difference Engine (1822) to solve differential equations.
P 9.
10.
The Analytical Engine was Charles Babbage's later concept for a general-purpose computer.
Herman Hollerith's Tabulating Machine (1889) used punched cards and was developed for the U.S.
R 11.
census.
The Z3 (1941), developed by Konrad Zuse, was used for designing airplanes and missiles.
E
12. The Harvard Mark I (1944) was an electromechanical relay computer.
13. ENIAC (1946) was the first general-purpose electronic computer.
14. EDVAC (1945), designed by John von Neumann, introduced the stored-program concept.
P 15. UNIVAC-I (1951) was one of the first commercially available computers.
16. Microcomputers (Personal Computers) are the smallest and least expensive class, originally for
A 17.
individual users.
Types of microcomputers include Desktop, Notebook, Laptop, and Handheld devices (Palmtop, PDA,
R 18.
Smartphone).
Mainframe computers are the second most powerful and expensive, used by large organizations for
A 19.
critical, bulk-data processing.
Mainframes support many terminals simultaneously and are used for census, ERP, financial
transactions, and airline reservations.
T 20. Supercomputers are the most powerful and expensive, designed for intense scientific, engineering,
and business applications.
I 21. Supercomputers are used for weather forecasting, weapon research, space exploration, and complex
simulations.
O 22. Mobile Computers are devices enabling mobile computing—processing and transmitting data
wirelessly.
N 23. Mobile computers include laptops, smartphones, tablets, and PDAs, featuring wireless connectivity
and portability.
S 24. Computer hardware refers to the physical, tangible components of a computer system (e.g., monitor,
keyboard, mouse, CPU).
25. The primary function of hardware is to store and execute software.
26. Computer software is a set of instructions that directs the computer on what to do and how to do it.
27. The primary function of software is to operate the hardware and perform specific tasks.
28. Hardware is physical and tangible, whereas software is logical and intangible.
29. Hardware executes software and performs physical work, while software provides instructions to the
hardware.
30. Hardware understands only binary (0s and 1s), and software provides instructions in binary form.
P a g e 10 | 20
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Practice MCQs
1. Which of the following is NOT one of the 6. Which type of software acts as an interface
four fundamental operations performed by all between the computer hardware and the
computers? application software?
M d) Storage
Answer: c) Communication
d) Customized Software
Answer: b) System Software
2. Which early computing device, considered 7. A software translator that converts the
K the first computer, used a system of sliding entire source code into machine code at once,
beads for calculations? producing an object file, is called a(n):
a) Analytical Engine a) Interpreter
b) Difference Engine b) Assembler
P c) Abacus
d) Pascaline
c) Compiler
d) Linker
R Answer: c) Abacus
3. The concept where both program
Answer: c) Compiler
8. Customized banking software developed
E
instructions and data are stored in the same for a specific bank is an example of which
memory was introduced by which computer? category of application software?
a) ENIAC a) General-Purpose Software
P b) Harvard Mark I b) Productivity Software
c) EDVAC c) Special-Purpose Software
A d) UNIVAC-I
Answer: c) EDVAC
d) System Software
Answer: c) Special-Purpose Software
R 4. Which type of computer is specifically
designed for intense scientific applications
9. Software that is copyrighted and
distributed free of charge for use, but whose
A and is the most powerful and expensive?
a) Mainframe Computer
source code is not made available for
modification, is known as:
b) Microcomputer
T
a) Open Source Software
c) Minicomputer b) Shareware
d) Supercomputer c) Freeware
I Answer: d) Supercomputer d) Firmware
5. What is the primary functional distinction Answer: c) Freeware
O between computer hardware and software?
a) Hardware is logical, software is physical.
10. Which component of the CPU is
specifically responsible for fetching,
N b) Hardware provides instructions, software
executes them.
decoding, and executing instructions, and
directing data flow?
S c) Hardware is tangible and performs
physical work, software is intangible and
a) Arithmetic Logic Unit (ALU)
b) Control Unit (CU)
provides instructions. c) Accumulator (AX)
d) Hardware is stored permanently, software d) Cache Memory
is temporary. Answer: b) Control Unit (CU)
Answer: c) Hardware is tangible and 11. Which CPU register holds the memory
performs physical work, software is address of the next instruction to be fetched
intangible and provides instructions. from memory?
a) Instruction Register (IR)
P a g e 16 | 20
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Chapter 4
Number Systems, Digital Logics and Data
Basics
K computers represent numbers, text, and multimedia, how they perform logical and arithmetic operations
using Boolean algebra and logic gates, and how complex data is organized and managed in database
systems. Mastery of these topics is essential for understanding the inner workings of all computational
devices.
P a g e 1 | 14
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
One Liners: Number Systems, Digital Logics and Data Basics
1. Data is a raw collection of facts, figures, and statistics related to an object, used for viewing past
activities and making future decisions.
2. Information is data that has been processed, manipulated, and organized into a meaningful and useful
E 10. To convert a decimal number to another base, repeatedly divide the decimal number by the target base
and record remainders from bottom to top.
11. To convert binary to octal, group bits into sets of three from the right, pad with leading zeros if
P needed, and convert each group to its octal digit.
12. To convert binary to hexadecimal, group bits into sets of four from the right, pad with leading zeros if
A needed, and convert each group to its hex digit.
13. To convert octal to binary, convert each octal digit to its 3-bit binary equivalent.
R 14. To convert hexadecimal to binary, convert each hex digit to its 4-bit binary equivalent.
15. Whole numbers (unsigned integers) use all bits for magnitude; for n bits, the range is 0 to (2ⁿ – 1).
A 16. Signed integers use the Most Significant Bit (MSB) as a sign bit: 0 for positive, 1 for negative.
17. The Two's Complement method is used to represent negative integers: invert all bits of the positive
P a g e 7 | 14
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Practice MCQs
1. What is the key difference between data d) 11110
and information? Answer: b) 11101
a) Data is processed, information is raw. 6. The binary number 11010101 is equivalent
E Answer: b) Capturing
3. Which number system uses a base of 8 and
how is the negative equivalent of a positive
binary number formed?
is historically significant for representing 3 a) Invert all bits.
P binary bits per digit? b) Invert all bits and subtract 1.
a) Decimal c) Invert all bits and add 1.
A b) Hexadecimal
c) Octal
d) Add 1 to the number.
Answer: c) Invert all bits and add 1.
R d) Binary
Answer: c) Octal
9. In a 32-bit single-precision floating-point
format, how many bits are allocated to the
A 4. What is the primary reason computers use
the binary number system internally?
mantissa (significand)?
a) 1 bit
P a g e 10 | 14
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Chapter 5
Operating Systems
What is Software?
Software represents the logical component of a computer system—the intangible instructions that bring
5. Operating Systems
hardware to life. Without software, even the most advanced computer hardware remains nothing more
than an inert collection of electronic circuits and components.
Formal Definition: Software is a comprehensive collection of computer programs, procedures, and
M associated documentation that instructs a computer on what tasks to perform and how to perform them.
It serves as the intermediary between human intentions and machine execution.
5. Operating Systems
3. System software manages computer hardware and provides a platform for running application software.
4. System software acts as an intermediary between hardware and user applications.
5. Operating systems, device drivers, and utility programs are examples of system software.
M 6. The purpose of system software is to manage hardware resources and create a stable environment for
other software.
7. Application software helps users perform specific tasks or solve particular problems.
K 8. Application software fulfills user needs directly through programs like word processors and web
browsers.
9. System software controls hardware; application software is controlled by users to perform tasks.
10. A computer cannot run without system software; application software is optional based on user needs.
P 11. System software is usually pre-installed; application software is installed by users.
12. An operating system is the most critical type of system software, acting as an interface between user
R and hardware.
13. The OS controls program execution and manages computer resources.
E 14. The primary purpose of an OS is to act as a resource manager for hardware and software resources.
15. An OS provides a user interface offering a stable way for users and applications to interact with
hardware.
P 16. A command line interface (CLI) is text-based, requiring users to type specific commands.
17. CLI is powerful and flexible but has a steep learning curve requiring command memorization.
A 18. DOS was one of the first widely-installed OS for IBM-compatible PCs using commands like DIR and
COPY.
R 19. UNIX is a powerful, multi-user, multitasking OS forming the basis for Linux and macOS.
20. A menu-driven interface presents users with screens of options, requiring no command memorization.
A 21. Menu-driven interfaces are simpler than CLI but less flexible, ideal for systems like ATMs.
22. A graphical user interface uses graphics and is interacted with via pointing devices like mice.
T 23. GUI is user-friendly and easier to learn but may be slower for advanced tasks compared to CLI.
24. Microsoft Windows evolved from an environment on top of DOS to a full-fledged GUI OS.
25. macOS is Apple's GUI OS known for user-friendly design.
I 26. Linux is a free, open-source OS kernel; distributions like Ubuntu provide complete user-friendly
systems.
O 27. CLI offers more precise control over file systems and OS compared to GUI.
28. GUI provides excellent multitasking with visual cues for multiple windows.
N 29. CLI can be faster for experienced users due to keyboard-only operation.
30. GUI uses more system resources to render graphics compared to CLI.
S 31. CLI is excellent for scripting and automating command sequences.
32. A single-user OS is designed for one person at a time.
33. A single-tasking OS runs only one application at a time (e.g., old MS-DOS).
34. A single-user multitasking OS allows one user to run multiple applications concurrently.
35. A multi-user OS allows multiple users to access system resources simultaneously.
36. Time-sharing divides CPU time into slices allocated among multiple users.
37. Batch processing OS collects jobs in batches and processes them without user interaction.
38. Batch processing is efficient for CPU utilization in tasks like payroll systems.
39. A disadvantage of batch processing is lack of interactivity and difficult debugging.
P a g e 18 | 25
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Practice MCQs
1. What is the fundamental role of System DIR and COPY?
Software? a) UNIX
a) To help users perform specific tasks like b) Windows 95
5. Operating Systems
word processing. c) DOS (Disk Operating System)
b) To manage and operate computer hardware, d) macOS
providing a platform for application software. Answer: c) DOS (Disk Operating System)
M c) To provide entertainment and games for
users.
6. What is a primary advantage of a
Graphical User Interface (GUI) over a
d) To connect the computer to the internet. Command Line Interface (CLI)?
K Answer: b) To manage and operate a) It offers more precise control over the file
computer hardware, providing a platform system.
for application software. b) It is faster for experienced users to perform
2. Which of the following is a key distinction complex tasks.
P between System Software and Application
Software?
c) It is more user-friendly and easier to learn,
using visual recognition.
R a) System Software is optional, Application
Software is essential.
d) It uses fewer system resources like RAM
and CPU.
P a g e 21 | 25
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Chapter 6
Artificial Intelligence (AI)
What is Artificial Intelligence?
Definition: Artificial Intelligence (AI) is the branch of computer science that aims to create systems
P Fundamental Goals of AI
The primary objectives of artificial intelligence research can be categorized into four main goals:
I •
Systems That Act Rationally
Systems that make optimal decisions to achieve goals
O •
•
Example: Autonomous robots that navigate efficiently
Approach: Rational agent theory and decision theory
Real-World Example: Consider a self-driving car. It must:
N • Think like humans: Understand traffic patterns intuitively
• Think rationally: Calculate optimal routes mathematically
S •
•
Act like humans: Signal before turning like human drivers
Act rationally: Make safe decisions to reach the destination
P a g e 1 | 52
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
• Knowledge representation using symbols
• Rule-based reasoning systems
• Explicit programming of knowledge
Example: Expert systems for medical diagnosis that use if-then rules:
R •
•
Learning from examples
Parallel processing
Example: Handwriting recognition systems that learn from thousands of handwriting samples.
E Advantages:
• Robust to noisy data
P •
•
Can learn complex patterns
Generalizes well to new examples
A Evolutionary Approach
Concept: Uses principles of natural selection and genetic algorithms.
R Characteristics:
• Population-based search
A •
•
Fitness-based selection
Crossover and mutation operations
T Example: Optimizing antenna designs by evolving thousands of virtual antennas and selecting the best
performers.
I Bayesian Approach
Concept: Uses probability theory to handle uncertainty.
O Characteristics:
• Probabilistic reasoning
N •
•
Bayesian networks
Statistical learning
S Example: Spam filters that calculate the probability of an email being spam based on word frequencies.
M return failure
Properties:
K •• Complete: Yes (if branching factor finite)
Optimal: Yes (if all actions have same cost)
• Time: O(b^d) where b = branching factor, d = depth
• Space: O(b^d) (stores all nodes)
Example: Finding shortest path in unweighted graph.
P 2. Depth-First Search (DFS)
R
function DFS(problem) returns solution or failure
frontier ← LIFO stack containing Node([Link])
E reached ← {[Link]}
A
node ← POP(frontier)
if [Link]-TEST([Link]) then return SOLUTION(node)
I return failure
Properties:
O
• Complete: No (can get stuck in infinite depth)
• Optimal: No
• Time: O(b^m) where m = maximum depth
N • Space: O(bm) (linear in depth)
3. Depth-Limited Search
S •
•
DFS with depth limit l
Returns failure if no solution within depth l
4. Iterative Deepening Search
function ITERATIVE-DEEPENING-SEARCH(problem) returns solution or failure
for depth = 0 to ∞ do
result ← DEPTH-LIMITED-SEARCH(problem, depth)
if result ≠ cutoff then return result
P a g e 13 | 52
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
for each a in ACTIONS(state) do
v ← MAX(v, MIN-VALUE(RESULT(state, a)))
return v
M v ← ∞
for each a in ACTIONS(state) do
K v ← MIN(v, MAX-VALUE(RESULT(state, a)))
return v
Properties:
• Complete: Yes (if tree finite)
P • Optimal: Yes (against optimal opponent)
• Time: O(b^m)
R • Space: O(bm) (depth-first)
Alpha-Beta Pruning
E function ALPHA-BETA-SEARCH(state) returns action
P v ← MAX-VALUE(state, -∞, ∞)
return the action in ACTIONS(state) with value v
A
R
function MAX-VALUE(state, α, β) returns utility value
if TERMINAL-TEST(state) then return UTILITY(state)
A v ← -∞
for each a in ACTIONS(state) do
T v ← MAX(v, MIN-VALUE(RESULT(state, a), α, β))
if v ≥ β then return v
I α ← MAX(α, v)
O return v
P a g e 18 | 52
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Ethical Frameworks
• Consequentialism: Judge by outcomes
• Deontology: Follow rules/duties
• Virtue Ethics: Focus on character
E Mitigation Strategies
• Pre-processing: Adjust training data
P •
•
In-processing: Modify learning algorithm
Post-processing: Adjust model outputs
A • Adversarial Debiasing: Use adversarial training
Transparency and Explainability
R Explainable AI (XAI)
A •
•
Interpretable Models: Simple, understandable models
Model Explanation: Explain complex model decisions
T •
•
Model Inspection: Understand how model works
Model Transparency: Clear about capabilities and limitations
I •
Explanation Methods
LIME: Local Interpretable Model-agnostic Explanations
O •
•
SHAP: Shapley Additive Explanations
Counterfactual Explanations: "What if" scenarios
N • Attention Visualization: Show what model focuses on
Right to Explanation
S •
•
GDPR Article 22: Right to meaningful information about logic involved
Need for human-understandable explanations
• Balancing transparency with intellectual property
P a g e 41 | 52
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
One-Liners: Artificial Intelligence (AI)
1. Artificial Intelligence is the science and engineering of making intelligent machines that can perform
tasks requiring human intelligence.
2. The Turing Test, proposed by Alan Turing in 1950, evaluates a machine's ability to exhibit intelligent
K 5. A rational agent selects actions that maximize its expected performance measure given its percept
sequence and built-in knowledge.
6. Breadth-First Search is complete and optimal for uniform cost but has exponential space complexity
O(b^d).
7. Depth-First Search uses linear space O(bm) but is neither complete nor optimal in infinite spaces.
P 8. A* search uses f(n) = g(n) + h(n) and is optimal if h(n) is admissible (never overestimates) and
complete if branching factor is finite.
R 9. An admissible heuristic never overestimates the cost to reach the goal, while a consistent heuristic
satisfies h(n) ≤ c(n,a,n') + h(n').
E 10. Minimax algorithm evaluates game trees assuming optimal play by both players, with time complexity
O(b^m) for depth m.
P 11. Alpha-beta pruning improves minimax by eliminating branches that cannot affect the final decision,
reducing time to O(b^(m/2)) in best case.
12. Propositional logic uses atomic sentences connected by operators (¬, ∧, ∨, ⇒, ⇔) and supports
A inference through resolution.
13. First-order logic extends propositional logic with quantifiers (∀, ∃), predicates, functions, and variables
R for more expressive knowledge representation.
14. Modus Ponens (α ⇒ β, α / ∴ β) and Resolution (α ∨ β, ¬β ∨ γ / ∴ α ∨ γ) are fundamental inference rules
A in logic.
15. Unification finds substitutions that make two logical expressions identical, enabling generalized modus
T ponens in first-order logic.
16. Machine learning algorithms improve their performance on a task through experience, measured by a
I performance metric.
17. Supervised learning uses labeled training data {(xᵢ, yᵢ)} to learn mapping f: X → Y for classification or
regression.
O 18. Unsupervised learning discovers patterns in unlabeled data through clustering, dimensionality
reduction, or association rule learning.
N 19. Reinforcement learning agents learn optimal policies through interaction with environment to maximize
cumulative reward.
S 20. Overfitting occurs when a model learns training data noise, while underfitting happens when model is
too simple to capture patterns.
21. Bias-variance tradeoff: simple models have high bias (underfit), complex models have high variance
(overfit).
22. Cross-validation estimates model performance by partitioning data into training and validation sets
multiple times.
23. Linear regression models continuous outputs using y = wᵀx + b, optimized by minimizing mean squared
error.
P a g e 45 | 52
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Practice MCQs
1. Which of the following best defines complexity?
Artificial Intelligence? a) Depth-First Search
a) Programming computers to perform specific b) Breadth-First Search
I
d) The computational efficiency of neural states that from α ∨ β and ¬β ∨ γ, we can
networks infer:
Answer: b) The possibility of computers a) α ∧ γ
O achieving true understanding b) α ∨ γ
4. A rational agent in AI is defined as one c) β ⇒ γ
N that:
a) Always makes perfect decisions
d) ¬α ⇒ γ
Answer: b) α ∨ γ
S b) Has complete knowledge of its environment
c) Maximizes expected performance given
9. First-order logic extends propositional logic
by adding:
available information a) Probabilistic reasoning capabilities
d) Mimics human decision-making processes b) Quantifiers, predicates, and variables
exactly c) Temporal operators for time reasoning
Answer: c) Maximizes expected d) Fuzzy logic for handling uncertainty
performance given available information Answer: b) Quantifiers, predicates, and
5. Which search algorithm is complete and variables
optimal but has exponential space
P a g e 48 | 52
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Chapter 7
Theory of Automata
Introduction to Automata Theory
7. Theory of Automata
The Foundation: What is Computation?
At its heart, computer science seeks to understand what can and cannot be computed, and the resources
required to do so. Before the advent of physical computers, mathematicians and logicians like Alan
Turing, Alonzo Church, Emil Post, and others sought to define the very notion of an "effective
M procedure" or "algorithm." Automata theory provides the formal models for these procedures.
Conceptual Definition: An automaton (plural: automata) is an abstract, mathematical model of a
K machine that follows a predetermined sequence of operations to process information. It is a finite
representation of a system that receives input, changes its internal state according to a set of rules, and
may produce output.
Real-Life Analogy: Consider a simple vending machine. It has a finite number of
P states: Idle, Amount_Entered_Partial, Amount_Entered_Full. It receives input (coins of different
denominations). Based on the current state and the input coin, it transitions to a new state (e.g.,
R from Idle to Amount_Entered_Partial). When the state Amount_Entered_Full is reached, it delivers the
product (output) and returns to Idle. This is a finite automaton in the physical world.
R 3. To Understand Limitations: It leads to profound, provable statements about the limits of computation
(e.g., the Halting Problem).
4. Foundations for Practical Tools: The theories directly underpin the design of compilers (lexical
A analysis, parsing), text processors (regular expression search), hardware design (sequential circuits),
and protocol analysis.
T The Chomsky Hierarchy: A Roadmap
I The central organizing framework of automata theory is the Chomsky Hierarchy, proposed by linguist
Noam Chomsky. It establishes a containment hierarchy of formal grammars and their corresponding
O recognizing machines. This hierarchy will be our guide throughout these notes.
Grammar Language Recognizing Production Memory
N Type Class Automaton Rules (Example) Constraint
S Type 0 Recursively
Enumerable
Turing Machine
(TM)
α→β
(Unrestricted)
Unlimited
P a g e 1 | 15
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Type 3 Regular Finite Automaton A → aB, A → a Finite
(FA) Memory
Table: The Chomsky Hierarchy showing the relationship between grammars, languages, and machines.
We will study these machines in ascending order of power: Finite Automata, Pushdown Automata,
7. Theory of Automata
and Turing Machines. Context-sensitive languages and LBAs are often covered at a more introductory
level in FPSC exams due to their complexity.
K
that is relevant for future actions is summarized in the current state. They are the simplest model in our
hierarchy.
A •
Example 2.1: Let's design a DFA that accepts all strings over Σ = {0, 1} that end with '01'.
Intuition: The machine must "remember" the last two symbols seen.
States:
T
•
o q₀: Start. Remembers nothing relevant or the last symbol was not '0'.
o q₁: Remembers that the last symbol was a '0'.
I o
•
q₂: Remembers that the last two symbols were '01' (ACCEPTING).
Transitions:
O o
o
In q₀, on input '0', go to q₁. On '1', stay in q₀.
In q₁, on input '0', stay in q₁. On '1', go to q₂.
N o
•
In q₂, on input '0', go to q₁. On '1', go to q₀.
**F = {q₂}`.
P a g e 2 | 15
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
One-Liners: Theory of Automata
1. DFA vs NFA: In DFA, δ: Q×Σ→Q; in NFA, δ: Q×Σ→P(Q) with possible ε-transitions.
7. Theory of Automata
2. Subset Construction: Converts NFA to DFA, where each DFA state represents a set of NFA states.
3. ε-closure: Set of all states reachable from a given state via ε-transitions alone.
4. Myhill-Nerode Theorem: Language L is regular iff it has finite number of equivalence classes under
M the indistinguishability relation.
K 5. Minimization Algorithm: Uses partition refinement to merge indistinguishable states in a DFA.
6. Arden's Theorem: If equation is X = AX + B, then smallest solution is X = A*B, provided ε∉A.
7. Left Linear Grammar: Productions of form A→Ba or A→a; Right Linear Grammar: A→aB or A→a.
P 8. Pumping Lemma Contrapositive: To prove L not regular, show ∀p ∃s∈L with |s|≥p such that ∀xyz=s
R with |xy|≤p & |y|>0, ∃i≥0 with xyⁱz∉L.
E 9. Regular Closure: Closed under all Boolean operations, concatenation, Kleene star, reversal,
homomorphisms.
P 10. CFG Ambiguity: Grammar ambiguous if ∃w∈L with ≥2 leftmost derivations or parse trees.
A 11. Inherent Ambiguity: Language where every CFG for it is ambiguous (e.g., {aⁿbⁿcᵐdᵐ} ∪ {aⁿbᵐcᵐdⁿ}).
R 12. CNF Conversion: Eliminates ε-productions, unit productions, then converts to A→BC or A→a.
13. Greibach Normal Form: All productions A→aα where α∈V* and a∈T.
A 14. PDA Acceptance Modes: Final state and empty stack are equivalent for nondeterministic PDA.
T 15. Deterministic PDA: At most one move for each (state, input, stack-top) combination.
I 16. DPDA Languages: DCFL properly contained in CFL; not closed under union, intersection.
O
17. CFL Pumping Lemma: For long strings z, can write z=uvwxy with vx non-empty, |vwx|≤p, and
uvⁱwxⁱy∈L ∀i≥0.
N 18. Ogden's Lemma: Strengthened pumping lemma where specific positions can be "marked."
S 19. CFL Closure: Closed under union, concatenation, Kleene star, homomorphism, reversal. Not closed
under intersection, complement.
20. CFL Intersection with Regular: Always a CFL (useful closure property).
21. CYK Algorithm: O(n³) dynamic programming algorithm for membership in a CFL given in CNF.
22. Turing Machine Configuration: Triple (state, tape contents, head position).
23. Multi-tape TM Simulation: k-tape TM can be simulated by 1-tape TM with O(T²(n)) time.
P a g e 9 | 15
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Practice MCQs
1. Which of the following statements about a) |xy| ≤ p
finite automata is FALSE? b) |y| > 0
a) Every NFA can be converted to an c) xyⁱz ∈ L for all i ≥ 0
7. Theory of Automata
equivalent DFA d) All conditions hold, so L is regular
b) Every DFA is also an NFA Answer: c) (Pumping y of 0s changes length
c) The language accepted by an NFA with n to not be multiple of 10)
M states may require a DFA with 2ⁿ states
d) An NFA with ε-transitions is more
7. A grammar with productions S → aS | bS
| a | b is:
I of 0s and 1s}
b) {w ∈ {0,1}* | w ends with 00}
string of length n is:
a) n
c) {w ∈ {0,1}* | w contains 010 as substring} b) 2n-1
O d) {0ⁿ | n is a prime number} c) n²
Answer: a) and d) are both not regular, but d) 2n
N if only one answer: a) is the classic example
**5. The regular expression
Answer: b) (2n-1 derivation steps)
11. The language {ww | w ∈ {0,1}*} is:
S (a+b)a(a+b)a(a+b)* generates:**
a) Strings with exactly two a's
a) Regular
b) Context-Free
b) Strings with at least two a's c) Context-Sensitive but not CF
c) Strings with at most two a's d) Recursive but not CS
d) Strings beginning and ending with a Answer: c) (Requires comparing arbitrary
Answer: b) positions, not possible with PDA alone)
6. Which pumping lemma condition is 12. A PDA with acceptance by empty stack
violated for L = {0¹⁰ⁿ | n ≥ 0} to prove it's and final state:
not regular? a) Are equivalent for deterministic PDAs
P a g e 12 | 15
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Chapter 8
Office Automation
Introduction to Office Automation
Office Automation refers to the use of computer software and systems to digitally create, collect, store,
8. Office Automation
manipulate, and relay office information to accomplish core tasks. The primary applications involved
are Word Processors, Spreadsheets, Database Management Systems, and Presentation Software. This
chapter provides a comprehensive guide to Word Processing and Spreadsheet software, their features,
M interfaces, and practical operations.
Word Processing
K What is a Word Processor?
A Word Processor is application software used for the composition, editing, formatting, and printing of
text-based documents. It goes beyond simple typing by allowing the manipulation of text, insertion of
P images, sounds, charts, graphics, and even video clips. Documents can be saved in various formats (.txt,
.rtf, .html, .doc, .docx) and published on the web with hyperlinks. Its greatest advantage over a typewriter
P a g e 1 | 19
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
• The file extension for an Outlook file is “.pst”
6. MS OneNote
• It was released on November 19, 2003
• It is a note-taking application
8. Office Automation
Microsoft Office Versions
• When introduced, it was a part of the Office suite only. Later, the developers made it free, standalone
and easily available at play store for android devices
The notes may include images, text, tables, etc.
M
•
• The extension for OneNote files is “.one”
• It can be used both online and offline and is a multi-user application
K Apart from the applications mentioned above, various other applications are included in the MS Office
suite but these are most commonly used ones and questions based on the same may be asked in the
upcoming exams as well.
Microsoft Office Versions
P When the Office suite was first released, it was entirely devoted for usage in computer systems but
R later with time the Office suite was modified for use in Laptops, Tablets and Mobile phones.
Given below are the various versions of Microsoft Office along with the years in which the version
E was released:
All the above-mentioned dates are for the Office suite released for Windows. Apart from these, the
versions Online, for Mac and for Mobile Phones were released separately
8. Office Automation
Management Systems, and Presentation Software.
3. A Word Processor is application software used for the composition, editing, formatting, and printing of
text-based documents.
M 4. A key advantage of a word processor over a typewriter is the ability to make changes without retyping
the entire document.
5. Text Editors (simple word processors) support only basic features like insert, delete, cut, copy, paste,
K and word wrap.
6. Full-Featured Word Processors support advanced capabilities like mail merge, macros, footnotes, and
table of contents generation.
7. The WYSIWYG (What You See Is What You Get) feature ensures the on-screen display matches the
P printed output.
8. The Title Bar in a word processor window displays the name of the active document and the
R application.
9. The Ribbon in modern word processors replaced menus and contains tabs grouping related commands.
E 10. The Quick Access Toolbar is a customizable bar for frequently used commands like Save, Undo, and
Redo.
11. The Ruler shows text positioning, tabs, margins, and indents both horizontally and vertically.
P 12. The Document Window is the main area for creating and editing, with a blinking cursor indicating the
insertion point.
A 13. The Status Bar shows document information such as page number, word count, and zoom level.
14. Ctrl+N is the keyboard shortcut to create a new document in most word processors.
R 15. Ctrl+S is the shortcut to save a document, while Ctrl+O is used to open an existing document.
16. Ctrl+P opens the Print dialog box for printing a document.
A 17. In Insert Mode (default), new text pushes existing text forward.
18. In Overtype Mode, new text overwrites existing text at the cursor position.
P a g e 11 | 19
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Practice MCQs
1. What is the primary purpose of Office 6. What is the keyboard shortcut to select all
Automation? text in a document?
a) To replace human workers entirely a) Ctrl+C
8. Office Automation
b) To use computer software to digitally b) Ctrl+V
create, store, manipulate, and relay office c) Ctrl+A
information d) Ctrl+X
M c) To design hardware for office use
d) To provide entertainment in the workplace
Answer: c) Ctrl+A
7. Which typing mode causes new text to
Answer: b) To use computer software to overwrite existing text at the cursor position?
K digitally create, store, manipulate, and a) Insert Mode
relay office information b) Overtype Mode
2. Which of the following is NOT a primary c) Replace Mode
application of office automation? d) Typeover Mode
P a) Word Processor
b) Spreadsheet
Answer: b) Overtype Mode
8. The temporary memory space used by the
R c) Operating System
d) Database Management System
operating system to hold cut or copied data
for pasting is called the:
P a g e 15 | 19
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Chapter 9
Microsoft Word (MS Word)
With Word you can:
Create a document from scratch or from a template .
Add text, images, art, and videos.
9. Microsoft Word
Research a topic and find credible sources.
Access your documents from a computer, tablet, or phone via OneDrive.
Share your documents and collaborate with others.
Track and review changes.
M Create a new document
1. On the File tab, select New.
K 2. Select Blank document, or double-click a template image or type the kind of document into the Search for
online templates box and press Enter.
Tip: For practice using Word features, try a learning guide like Welcome to Word or Insert your first table
of contents.
P Add and format text
R
E
P
A
R
A
T
I
1. Click on your new blank page and type some text.
O
2. Select text to format and choose font options on the Home tab: Bold , Italic , Bullets , Numbering , and
N more.
P a g e 0 | 21
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
2. On Shape Format or Drawing Tools Format, select Text Fill or Text Outline, and pick the color you
want.
8. MS Word
M
K
R
E
P
A Choose a text effect
1. Select the WordArt text to change.
R
A
T
I
O
N
S
2. Go to Shape Format or Drawing Tools Format > Text Effects >Transform.
Pick the effect you want.
3. Click outside of your text box to see the effect.
P a g e 5 | 21
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
2. Go to Layout, and open the Page Setup dialog box.
8. MS Word
M 3. Select Landscape, and in the Apply to box, choose Selected text.
K
Add a border to a page
1. Go to Design > Page Borders.
P
R
E
P
A 2. Make selections for how you want the border to look.
R
A
T
I
O
N
S
P a g e 11 | 21
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
One Liners: MS Word
8. MS Word
1. Microsoft Word allows you to create documents from scratch or from an online template.
2. You can research topics and find credible sources directly within Microsoft Word.
3. Documents can be accessed from a computer, tablet, or phone via OneDrive.
4. Word facilitates document sharing and collaboration with others.
5. The Track and Review changes feature is available in Microsoft Word.
6. A new blank document is created from the File tab by selecting New and then Blank document.
7. To create a document from a template, you can double-click a template image or search in
the Search for online templates box.
M 8.
9.
Learning guides like Welcome to Word are available for practice with Word features.
Text is formatted using options on the Home tab such as Bold, Italic, Bullets, and Numbering.
K 10. The Insert tab is used to add elements like Tables, Pictures, Shapes, SmartArt, Charts, and
Screenshots.
11. A table is inserted by selecting Insert > Table and hovering over a grid to choose the number of
rows and columns.
12. For a larger or customized table, use Insert > Table > Insert Table.
P 13. Existing text separated by tabs can be converted to a table using Insert > Table > Convert Text to
Table.
R 14.
15.
You can draw a custom table using Insert > Table > Draw Table.
To add text, place the cursor at the desired location and start typing.
E 16.
17.
To replace text, select it and start typing; double-click selects a single word.
Clicking to the left of a line selects the entire line.
P 18.
19.
Text formatting can be applied from the pop-up toolbar or the Home tab's Font group.
The Format Painter tool copies formatting from one text selection to another.
20. Double-clicking the Format Painter allows copying formatting to multiple locations.
A 21. To save a document to OneDrive, use File > Save As or Save a Copy and select OneDrive.
22. Save personal files to OneDrive - Personal and work files to your company's OneDrive or
R 23.
SharePoint site.
You can also save a document to other locations like the Desktop by selecting Browse.
A 24.
25.
AutoSave automatically saves changes when a document is stored in OneDrive or SharePoint.
AutoSave can be toggled on or off from the Quick Access Toolbar.
T 26. The Quick Access Toolbar can be shown by right-clicking the ribbon and selecting Show Quick
Access Toolbar.
I 27. Pictures can be inserted from your PC (This Device), from Stock Images, or from the web (Online
Pictures).
28. In older Word versions, the option for online pictures may be labeled Online Pictures next
O to Pictures.
29. To resize a picture, select it and drag a corner handle.
N 30. Text wrapping options control how text flows around a picture; selecting any option other than In
Line with Text allows you to move the picture.
S 31. In Line with Text layout places a picture within a paragraph, causing it to move as text is added or
removed.
32. WordArt is inserted via Insert > WordArt; you can pick a style and type your text.
33. Existing text can be converted to WordArt by selecting the text first, then going to Insert >
WordArt.
34. The color of WordArt text is changed using Text Fill or Text Outline on the Shape
Format or Drawing Tools Format tab.
P a g e 13 | 21
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Practice MCQs
8. MS Word
1. In Microsoft Word, where do you go to
text paragraph, causing it to move as text is
create a brand new document from a blank
edited?
slate? a) Square
a) Home > New b) Tight
b) File > New > Blank document c) Behind Text
c) Insert > New Document d) In Line with Text
d) View > New Window Answer: d) In Line with Text
Answer: b) File > New > Blank document7. You want to start page numbering from
E
a) Insert > Table > Draw Table a) Design > Watermark > Custom Watermark >
b) Insert > Table > Excel Spreadsheet Picture watermark
c) Insert > Table > Convert Text to Table
b) Insert > Picture > Set as Watermark
P d) Layout > Convert > Text to Table c) Page Layout > Background > Custom
Answer: c) Insert > Table > Convert Text to
Watermark
A Table
4.
d) View > Watermark > Insert Picture
Answer: a) Design > Watermark > Custom
What is the primary function of the
R Format Painter tool in Word?
a) To change the page color
Watermark > Picture watermark
9. Which key must you hold down while
A b) To copy formatting from one text selection
to another
dragging a shape's rotation handle to constrain
the rotation to 15-degree increments?
c) To insert painterly art effects a) Ctrl
T d) To adjust paragraph spacing b) Alt
Answer: b) To copy formatting from one text
c) Shift
I selection to another d) Tab
5. Answer: c) Shift
How do you ensure that the header on
O the first page of your document is different
from the rest (e.g., blank)?
10. If the Quick Access Toolbar is not
visible, how can you display it?
N a) Delete the header on the first page manually.
a) Go to File > Options > Quick Access
b) Insert a section break after the first page.
Toolbar.
10. MS Excel
patterns with data bars, color coding, and icons.
Create a workbook
1. Open Excel.
M 2. Select Blank workbook. Or press Ctrl+N.
P
R
E
P
A Enter data
To manually enter data:
R 1. Select an empty cell, such as A1, and then type text or a number.
2. Press Enter or Tab to move to the next cell.
A To fill data in a series:
1. Enter the beginning of the series in two cells: such as Jan and Feb; or 2014 and 2015.
T 2. Select the two cells containing the series, and then drag the fill handle across or
down the cells.
I
O
N
S
P a g e 0 | 39
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
there is only one number reference in this formula. The Intellisense tag will appear for any
function.
AutoSum horizontally
9. MS Excel
M
K
P a g e 3 | 39
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
What can I use in a formula to mimic calculator keys?
9. MS Excel
=4+6+2
- (Minus key) - (minus) Use in a formula to subtract numbers or to
signify a negative number. 6
Example: =18-12 -120
M Example: =24*-5 (24 times negative 5)
A Example: =1/8
9. MS Excel
the Home tab in the Number group.
M Format Description
General The default number format that Excel applies when you type a number. For the most
K part, numbers that are formatted with the General format are displayed just the way
you type them. However, if the cell is not wide enough to show the entire number,
the General format rounds the numbers with decimals. The General number format
also uses scientific (exponential) notation for large numbers (12 or more digits).
P Number Used for the general display of numbers. You can specify the number of decimal
places that you want to use, whether you want to use a thousands separator, and how
R you want to display negative numbers.
Currency Used for general monetary values and displays the default currency symbol with
E numbers. You can specify the number of decimal places that you want to use,
whether you want to use a thousands separator, and how you want to display
P negative numbers.
Accounting Also used for monetary values, but it aligns the currency symbols and decimal
A points of numbers in a column.
Date Displays date and time serial numbers as date values, according to the type and
R locale (location) that you specify. Date formats that begin with an asterisk (*)
respond to changes in regional date and time settings that are specified in Control
A Panel. Formats without an asterisk are not affected by Control Panel settings.
Time Displays date and time serial numbers as time values, according to the type and
T locale (location) that you specify. Time formats that begin with an asterisk (*)
respond to changes in regional date and time settings that are specified in Control
I Panel. Formats without an asterisk are not affected by Control Panel settings.
Percentage Multiplies the cell value by 100 and displays the result with a percent (%) symbol.
O You can specify the number of decimal places that you want to use.
Fraction Displays a number as a fraction, according to the type of fraction that you specify.
N Scientific Displays a number in exponential notation, replacing part of the number with E+n,
where E (which stands for Exponent) multiplies the preceding number by 10 to the
S nth power. For example, a 2-decimal Scientific format displays 12345678901 as
1.23E+10, which is 1.23 times 10 to the 10th power. You can specify the number of
decimal places that you want to use.
Text Treats the content of a cell as text and displays the content exactly as you type it,
even when you type numbers.
P a g e 10 | 39
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
This unlocks all the cells on the worksheet when you protect the worksheet. Now, you can choose
the cells you specifically want to lock.
5. On the worksheet, select only the cells that you want to lock.
6. Bring up the Format Cells popup window again (Ctrl+Shift+F).
7. This time, on the Protection tab, check the Locked box and then select OK.
9. MS Excel
8. On the Review tab, select Protect Sheet.
M
K
P
9. In the Allow all users of this worksheet to list, choose the elements that you want users to
R be able to change.
More information about worksheet elements
E
Clear this check box To prevent users from
P Moving the pointer to cells for which the Locked check box is selected on
A Select locked cells the Protection tab of the Format Cells dialog box. By default, users are
allowed to select locked cells.
R Moving the pointer to cells for which the Locked check box is cleared on
the Protection tab of the Format Cells dialog box. By default, users can
Select unlocked cells
A select unlocked cells, and they can press the TAB key to move between the
unlocked cells on a protected worksheet.
T Changing any of the options in the Format Cells or Conditional
Formatting dialog boxes. If you applied conditional formats before you
Format cells
I protected the worksheet, the formatting continues to change when a user
enters a value that satisfies a different condition.
O Format columns
Using any of the column formatting commands, including changing
column width or hiding columns (Home > Format).
N Format rows
Using any of the row formatting commands, including changing row
height or hiding rows (Home > Format).
S Insert columns
Insert rows
Inserting columns.
Inserting rows.
Insert hyperlinks Inserting new hyperlinks, even in unlocked cells.
Deleting columns.
Delete columns If Delete columns is protected and Insert columns is not also protected, a
user can insert columns that they cannot delete.
P a g e 20 | 39
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
One Liners: MS Excel
1. Excel simplifies numerical calculations and data entry with features like AutoFill.
2. Chart recommendations based on your data can be created with a single click in Excel.
9. MS Excel
3. Trends and patterns can be easily visualized using data bars, color coding, and icons in
Excel.
4. A new blank workbook is created by selecting Blank workbook or pressing Ctrl+N.
M 5. To enter data manually, select a cell, type, and press Enter or Tab to move to the next cell.
K 6. The AutoFill series is created by entering the start of the series in two cells and dragging
the fill handle.
7. Excel can perform calculations using simple formulas for addition, subtraction,
P multiplication, and division.
R 8. All Excel formulas must begin with an equal sign (=).
E 9. The basic arithmetic operators are: plus (+) for addition, minus (-) for subtraction, asterisk
(*) for multiplication, and forward slash (/) for division.
P 10. There is no dedicated SUBTRACT function in Excel; the minus operator (-) is used
A within a formula.
R 11. The SUM function can incorporate negative numbers using a minus sign, e.g.,
=SUM(12,5,-3,8,-4).
A 12. The AutoSum feature automatically senses a contiguous range and inserts a SUM
T formula.
I 13. AutoSum can be applied both vertically (above/below a range) and horizontally (left/right
of a range).
O 14. AutoSum does not work on non-contiguous ranges of cells.
N 15. The Intellisense guide for a function appears as a floating tag and provides a hyperlink to
9. MS Excel
c) Ctrl+W a) =A1
d) Ctrl+T b) =$A$1
Answer: b) Ctrl+N c) =B1
2. To automatically fill a series like "Jan, d) =A2
M Feb, Mar..." what must you do first? Answer: c) =B1
a) Type the entire series once. 7. In Excel, which function is equivalent to
K b) Use the Fill Series dialog box. the calculator's square root (√) key?
c) Enter the beginning of the series in a) SQR
two cells and select them. b) ROOT
d) Select the cells and choose "Fill c) SQRT
P Series" from the Data tab. d) POWER(...,0.5)
Answer: c) Enter the beginning of the Answer: c) SQRT
R series in two cells and select them. 8. Where is a watermark picture inserted in
3. What is a fundamental requirement for an Excel worksheet to appear behind the
E every Excel formula? data?
a) It must contain a function. a) As a background from the Page
P b) It must reference another cell. Layout tab.
c) It must begin with an equal sign (=). b) Into the header or footer via Insert >
A d) It must be enclosed in parentheses. Header & Footer.
Answer: c) It must begin with an c) As an inline image on the worksheet.
R equal sign (=). d) Using the Watermark option on the
4. How does Excel handle subtraction Design tab.
A within a formula, given there is no Answer: b) Into the header or footer
SUBTRACT function? via Insert > Header & Footer.
T a) It uses the SUM function with 9. What happens to the contents of cells
negative numbers. B2, C2, and D2 when they are merged
I b) It uses the DIF function. into one cell?
c) It uses the minus (-) operator. a) All contents are concatenated.
O d) Both a and c are correct. b) Only the content of the upper-left cell
Answer: d) Both a and c are correct. (B2) is kept.
N 5. The AutoSum feature is designed to c) The contents are averaged.
work with which type of cell ranges? d) An error message appears.
S a) 3-D references Answer: b) Only the content of the
b) Non-contiguous ranges upper-left cell (B2) is kept.
c) Contiguous ranges 10. After inserting a new row, the "Insert
d) Array ranges Options" button allows you to:
Answer: c) Contiguous ranges a) Choose the data source for the new
row.
P a g e 33 | 39
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Chapter 11
Microsoft PowerPoint (MS PowerPoint)
What is PowerPoint?
Overview
A
R
A
T
I
O
N
Add a slide
S 1. In the thumbnails on the left pane, select the slide you want your new slide to follow.
2. In the Home tab, in the Slides section, select New Slide.
P a g e 1 | 50
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Browse for the picture you want, select it, and then select Insert.
3. To add illustrations:
In the Illustrations section, select Shapes, Icons, 3D Models, SmartArt, or Chart.
In the dialog box that opens when you click one of the illustration types, select the item you
want and follow the prompts to insert it.
P Save in PowerPoint
Save your presentation to OneDrive
R When you save your files to the cloud, you can share and collaborate with others, and get to your files
from anywhere - on your computer, tablet, or phone.
E 1. Select File > Save As.
2. Select OneDrive.
P Save personal files to OneDrive - Personal, and work files to your company OneDrive. You can
also save to another location, like your device.
A
R
A
T
I
O
N
S
P a g e 3 | 50
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
To move to the previous or next slide, select Previous or Next.
To view all the slides in your presentation, select See all slides.
R
E
P
A
R
A
If you don’t see the Notes pane or it is completely minimized, click Notes on the task bar across the
bottom of the PowerPoint window
T Subtitles
You can choose which language the caption/subtitle text should be shown to your audience. This feature
I requires Windows 10 and an up-to-date version of PowerPoint.
1. Select Slide Show > Subtitle Settings.
O 2. Set your Spoken Language.
3. Select Subtitle Language to see which languages PowerPoint can display on-screen as captions or
N subtitles, and select the one you want.
4. In the Subtitle Settings menu, set the desired position of the captions or subtitles.
S 5. More appearance settings are available by selecting Subtitle Settings > More Settings (Windows).
What is a slide master?
When you want all your slides to contain the same fonts and images (such as logos), you can make those
changes in one place—the Slide Master, and they'll be applied to all your slides. To open Slide Master view,
on the View tab, select Slide Master:
The master slide is the top slide in the thumbnail pane on the left side of the window.
P a g e 6 | 50
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Rotate (mirror) text in a shape or text box
1. Insert a text box or shape in your document, and then type and format your text.
2. Right-click the box or shape and select Format Shape.
3. In the Format Shape pane, under Shape Options, select Effects.
P
R
E
P
A 6. (Optional) To remove the text box outline, right-click the text box, click Outline in the mini toolbar
that appears, and choose No Outline .
A
T
I
O
To change the horizontal alignment of a single paragraph or line:
N 1. Click in the paragraph or line of text that you want to modify.
2. On the Home tab (or the Message tab in Outlook), click the horizontal alignment option that you
S want.
P a g e 17 | 50
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
To view a detail in your slide up close, select Zoom into slide, and then point to the part you want to
see.
P Press the Esc key when you want to turn off the pen, laser pointer, or highlighter.
To hide or unhide the current slide in your presentation, select Black or unblack slide show.
R
E
P
You can use PowerPoint on your smartphone as a remote control to run your presentation and view your
A speaker notes. See Using a laser pointer on your smartphone when presenting in PowerPoint for more
information, including a brief video.
R Swap the Presenter view and Slide view monitors
To manually determine which screen shows your notes in Presenter view and which shows only the slides
A themselves, on the task bar at the top of Presenter view, select Display Settings, and then select Swap
Presenter View and Slide Show.
T
I
O
N
S
P a g e 29 | 50
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
One Liners: MS Power Point
1. PowerPoint allows you to create presentations from scratch or from professionally designed
templates.
E 7. Text is formatted using options like Font, Bold, Italic, Increase Font Size, and Decrease Font
Size in the Home tab's Font section.
P 8. Bulleted or numbered lists are created by selecting text and choosing Bullets or Numbering on
R 9. Pictures are inserted from the Insert tab, Images section, by selecting Pictures and choosing a
source.
A 10. Illustrations such as Shapes, Icons, 3D Models, SmartArt, and Charts are inserted from
I 11. To save a presentation to the cloud for access and collaboration, use File > Save As and
select OneDrive.
O 12. Save personal files to OneDrive - Personal and work files to your company OneDrive.
N 13. AutoSave is always on when you're online and saves changes as you work; pending changes sync
M
K
Keyboard Shortcut keys:
P
R
E
P
A
R
A
T 1. Set of one or more keys that generates a particular command to be executed.
2. Generally executed by using Alt or Ctrl keys with some other keys
I 3. A plus (+) sign between two or more keys indicates that these keys should
pressed in combination. For example Ctrl+Shift+A means to press and hold Ctrl
O and Shift and then press A
N
S
P a g e 1 | 22
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Frequently used Keys:
Key Function
K
Space bar • Move the curser one space forward
Tab Key
• Move the cursor several space foreword
A Enter Key
• In a dialogue box enable the highlighted option
•
R
In some program start the next operation or
confirm the current operation
S Shift + Del
F1
Delete selected item
Universal help (for all programs)
F2 Rename selected icon
F3 Start find from desktop
F5 Refresh contents or webpage
Alt + F4 Close currant open program
Ctrl + F4 Close window in program
P a g e 2 | 22
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Ctrl + H Open find and replace option Ctrl + Space Select entire column
Create formula to sum all
Ctrl + U Underline highlighted selection Alt + =
above cells
Ctrl + Y Underline highlighted text Ctrl + W Close document
Strike through highlighted Insert value of above cell into
Ctrl + 5 Ctrl + ‘
E Ctrl + Spacebar
Shift + F3
Reset manual character formatting
Change the case of selected text.
P Alt + Q
Ctrl + T
"Tell me what you want to do".
Open the Font window.
A Ctrl + K
Ctrl + Tab
Insert a hyperlink.
Switch between open presentations.
R Alt + F9
Alt + F10
Show/hide gridlines and guides
Show/hide selection pane.
A Alt + N Access the Insert tab.
Alt + H Access the Home tab.
T Esc End the slideshow.
Shift + F5 Start the slideshow from the current slide.
I F5 Start the slideshow from the beginning.
P a g e 5 | 22
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Win + Tab Cycle through open programs on task bar
Win + F Display the windows search / find feature
Win + Ctrl + F Display the search for computers window
Win + F1 Display the Microsoft windows help
Win + R Open the run window
K Command + A
Command + C
Select all items.
Copy selected items.
Command + V Paste copied items.
Command + X Cut selected items.
P a g e 7 | 22
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
One Liners: Keyboard and shortcut Keys
1. A keyboard is a panel of keys used to operate a computer or typewriter.
2. A keyboard is a piece of computer hardware used to input text, characters, and other commands.
E 11. The Control (Ctrl) key is a modifier key pressed in conjunction with another key to perform a specific
task.
P 12. The Backspace key moves the cursor one space backward.
A 13. The Enter key moves the cursor to the beginning of the next line.
R 14. The Enter key enables the highlighted option in a dialogue box.
15. The Enter key can start the next operation or confirm the current operation in some programs.
A 16. The Shift key, combined with another letter, types an uppercase letter.
T 17. The Shift key, combined with another key, types the symbol shown on the upper part of that key.
I 18. Alt + F opens the File menu options in the current program.
19. Alt + E opens the Edit options in the current program.
O 20. Ctrl + A selects all text.
N 21. Ctrl + X cuts the selected item.
P a g e 19 | 22
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Chapter 13
P 3. Message: The actual information or data to be communicated. This can be text, numbers,
pictures, sound, video, or any combination thereof.
A 4. Transmission Medium (Channel): The physical path through which the message travels from
sender to receiver (e.g., twisted-pair cable, fiber optics, or the atmosphere).
R 5. Protocol: A set of pre-defined rules and conventions that govern all aspects of communication. It
represents an agreement between devices on how data is formatted, transmitted, received, and
A acknowledged. Without a common protocol, effective communication is impossible. Protocols
handle error detection, synchronization, and signaling.
T Example: When you send an email, your laptop (Sender) uses the SMTP protocol to send the email text
(Message) over a Wi-Fi connection (Medium) to your email provider’s server (Receiver).
I In more detailed systems, we also consider Encoder and Decoder (Codec). An encoder converts digital
signals into a form suitable for the transmission medium (e.g., modulation), while a decoder performs the
O reverse process (demodulation) at the receiving end.
Key Characteristics of an Effective Network
N For a network to be functional and efficient, it must strive to meet three primary goals, often encapsulated
P a g e 1 | 41
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
o Characteristics: Centralized management, high security, scalable. Requires expensive
server hardware/admin.
o Example: Corporate email, web browsing.
• Peer-to-Peer (P2P):
E
Provides interface
for user/apps to HTTP, FTP, SMTP, DNS,
7 Application Data
access network Telnet
P services.
Translation,
A 6 Presentation encryption,
compression.
SSL/TLS, JPEG, MPEG,
ASCII/EBCDIC
Data
R 5 Session
Establishes,
manages, terminates NetBIOS, RPC, SIP Data
A sessions/dialogues.
End-to-end process-
T 4 Transport
to-process
communication, TCP (reliable), UDP (fast) Segment/Datagram
reliability, flow
I control.
Logical addressing
O 3 Network (IP), routing across
multiple networks.
IP, ICMP, IGMP, Routers Packet
N Node-to-node
delivery on same
Ethernet, PPP, Switches,
S 2 Data Link link, framing,
physical addressing
Bridges, NICs
Frame
(MAC).
Transmits raw bit
stream over physical
RS-232, 100Base-TX, Hubs,
1 Physical medium. Defines Bit
Repeaters, Cables
electrical/mechanical
specs.
P a g e 6 | 41
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
One Liners: Data Communication & Networking
FOUNDATIONAL CONCEPTS
1. Data communication is the electronic exchange of digital information between two or more
devices via a transmission medium.
A 12. UTF-8 is a variable-length Unicode encoding that maintains backward compatibility with ASCII.
13. Attenuation is the loss of signal strength as it travels through a medium, measured in decibels
T (dB).
14. Amplification is the process of strengthening an attenuated signal using devices like amplifiers
I or repeaters.
15. Distortion occurs when different frequency components of a signal arrive at different times,
O changing the signal's shape.
16. Noise is any unwanted external signal that mixes with and corrupts the original signal during
N transmission.
17. Crosstalk is a specific type of noise where signals leak from one cable or channel into an
S adjacent one.
18. In simplex mode, communication is unidirectional with one permanent sender and one permanent
receiver.
19. Half-duplex mode allows two-way communication but not simultaneously; devices must take
turns.
20. Full-duplex mode enables simultaneous two-way communication, requiring either two channels
or channel division.
P a g e 14 | 41
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Practice MCQs
1. In data communication, which external signals
component is responsible for c) Involves change in signal shape due
converting a message into a signal to varying propagation speeds of its
M b) Protocol
c) Encoder
Answer: c) Involves change in signal
shape due to varying propagation
K d) Transmission Medium
Answer: c) Encoder
speeds of its components
6. The metallic shield in a coaxial cable
2. The property of a communication serves the primary purpose of:
system that ensures data is delivered a) Providing structural rigidity
P as it is produced, without significant
delay or jitter, is called:
b) Acting as the primary data conductor
c) Shielding the central conductor from
R a) Delivery electromagnetic interference
b) Accuracy d) Reducing the cable's weight
E c) Timeliness Answer: c) Shielding the central
d) Synchronization conductor from electromagnetic
P Answer: c) Timeliness interference
3. Which characteristic of an analog 7. In fiber optic communication, total
A signal refers to the position of the internal reflection occurs because:
wave relative to a point in time?
R
a) The core has a higher refractive index
a) Amplitude than the cladding
A b) Frequency
c) Phase
b) The cladding has a higher refractive
index than the core
T d) Wavelength
Answer: c) Phase
c) Both core and cladding have identical
refractive indices
Pattern Recognition
T Definition: Identifying similarities, trends, or regularities within data or across different problems.
Purpose: Allows for the reuse and adaptation of known solutions, increasing efficiency and helping in
I predicting or generalizing solutions.
Examples:
O • Mathematics: Observing that the area of squares (1, 4, 9, 16, 25…) follows the pattern of adding
consecutive odd numbers (1, 1+3, 1+3+5, etc.).
N • Behavioral: Noticing you often forget homework on Mondays establishes a pattern, leading to a
solution like setting a Sunday reminder.
S • Data Analysis: Analyzing website traffic to identify which pages users visit most frequently or
common navigation paths they follow.
Abstraction
Definition: The process of filtering out irrelevant details and focusing only on the essential
information needed to solve the problem. It involves creating a general model.
Purpose: Reduces complexity by hiding unnecessary details, allowing one to work with a simplified
P a g e 1 | 21
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
1 1 3 3 1 ≤ 3, no change.
2 4 3 4 4 > 3, update max.
... ... ... ... ...
Standard Algorithms
P Sorting Algorithms
A Process of arranging data in order (ascending/descending).
P a g e 8 | 21
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
One Liners: Computational Thinking and Algorithm
1. Computational Thinking is a structured problem-solving methodology inspired by computer science
but applicable to all fields.
M 3. Decomposition is the process of breaking a large, complex problem into smaller, more manageable
K sub-problems.
4. Pattern Recognition involves identifying similarities, trends, or regularities within data or across
different problems.
P 5. Abstraction is the process of filtering out irrelevant details to focus only on the essential information
P 7. A core guiding principle of CT is Problem Understanding, the thorough analysis of a problem to define
A 9. The Input-Process-Output (IPO) model is the fundamental structure for any computational solution.
T 10. An IPO Chart is a simple tabular tool used to visually plan a solution based on Input, Process, and
Output.
I 11. A Simple Problem has a clear cause and straightforward solution, requiring fewer resources.
O 12. A Complex Problem has multiple interconnected causes, requires significant resources, and may have
N no guaranteed solution.
13. A Decision Problem is one where the solution is a binary "yes-or-no" (true/false) answer for a given
S input.
14. A Search Problem involves finding a specific item, path, or configuration that satisfies given criteria
from a set of possibilities.
P a g e 12 | 21
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
a) Input, Program, Outcome c) Feasibility
b) Instruction, Process, Output d) Generality
c) Input, Process, Output Answer: b) Finiteness
d) Initialize, Process, Operate 9. An algorithm that solves a problem by
Answer: c) Input, Process, Output dividing it into independent sub-problems,
P
pant), you must apply the: b) Parallelogram
a) Addition Principle c) Diamond
b) Subtraction Principle d) Oval
R c) Multiplication Principle Answer: c) Diamond
d) Division Principle 11. The primary advantage of using pseudocode
E 6.
Answer: c) Multiplication Principle
The formula nCr = n! / (r!(n-r)!) is used to
over a flowchart for algorithm design is:
a) It provides a visual representation.
P calculate:
a) The number of permutations of *r* items
b) It is easier to write and modify for
complex logic.
A from *n*
b) The number of combinations of *r* items
c) It uses standardized graphical symbols.
d) It can be directly executed by a computer.
from *n* Answer: b) It is easier to write and modify
R c) The number of ways to arrange *n* items for complex logic.
in a line 12. A manual, step-by-step execution of an
A d) The sum of all possible selections algorithm using sample data to check for
Answer: b) The number of combinations logical errors before coding is known as a:
T 7.
of *r* items from *n*
The Pigeonhole Principle guarantees that if
a) Simulation
b) Dry Run
I you have 15 students and only 12 lockers,
then:
c) Compilation
d) Validation
O a) Every locker will be used.
b) At least one locker will be empty. 13.
Answer: b) Dry Run
Which algorithm evaluation parameter is
c) At least one locker will contain more than concerned with how well an algorithm uses
N one item. time and memory resources?
d) The number of lockers must be increased. a) Correctness
S Answer: c) At least one locker will contain
more than one item.
b) Clarity
c) Efficiency
8. Which characteristic of a good algorithm d) Reliability
explicitly requires that it must stop after a Answer: c) Efficiency
finite number of steps? 14. The sorting algorithm that works by
a) Definiteness repeatedly comparing adjacent elements and
b) Finiteness swapping them if they are in the wrong order
P a g e 17 | 21
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Chapter 15
Programming Fundamentals
The Foundations of Computing & Programming
Introduction to Computing & Binary
R
o 1 Terabyte (TB) = 1024 GB
This system was formally refined by Gottfried Leibniz. Inside a computer, bits are represented by the
state of electronic switches (open/closed) or electrical signals (off/on) in components like the CPU and
E RAM.
Binary vs. Decimal Number Systems
P Base
Feature
10
Decimal System (Base-10)
2
Binary System (Base-2)
A Digits Used
Place Value
0, 1, 2, 3, 4, 5, 6, 7, 8, 9
Powers of 10 (..., 1000, 100, 10, 1)
0, 1
Powers of 2 (..., 8, 4, 2, 1)
R Smallest Unit
Example
Digit
1980 =
Bit (Binary Digit)
1010₂ = (1x8)+(0x4)+(1x2)+(0x1) =
A Notation
(1x1000)+(9x100)+(8x10)+(0x1)
Written as 45 or 45₁₀
10₁₀
Written with a subscript, e.g., 110₂
T In a binary number, the leftmost bit is the Most Significant Bit (MSB) and the rightmost bit is
the Least Significant Bit (LSB).
Number System Conversion
I Binary to Decimal Conversion: Use the positional notation method. Multiply each bit by 2 raised to
the power of its position (starting from 0 on the right) and sum the results.
O Example: 101101₂ = (1x2⁵)+(0x2⁴)+(1x2³)+(1x2²)+(0x2¹)+(1x2⁰) = 32+0+8+4+0+1 = 45₁₀.
Decimal to Binary Conversion: Use the repeated division-by-2 method.
N 1.
2.
Divide the decimal number by 2.
Write down the remainder (0 or 1).
S 3.
4.
Use the quotient as the new number.
Repeat steps 1-3 until the quotient is 0.
5. The binary number is the sequence of remainders read from the last to the first.
Example: Convert 172₁₀.
172 ÷ 2 = 86 R 0
86 ÷ 2 = 43 R 0
43 ÷ 2 = 21 R 1
21 ÷ 2 = 10 R 1
P a g e 1 | 18
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
<html lang="en">
<head>
<title>Page Title</title>
</head>
<body>
<!-- Visible content -->
R
html
<form action="/submit" method="POST">
<label for="name">Name:</label>
E <input type="text" id="name" name="name"><br>
<input type="radio" id="male" name="gender" value="male">
P <label for="male">Male</label><br>
<input type="submit" value="Submit">
</form>
A HTML Tables: Organize data.
html
R <table>
<tr><th>Name</th><th>Class</th></tr>
<tr><td>Alia</td><td>9</td></tr>
A </table>
Cascading Style Sheets (CSS)
T Controls presentation, layout, and styling, separating content from design.
Ways to Use CSS:
I 1. Inline: Within an HTML tag using style.
2. Internal (Embedded): Within a <style> tag in the <head>.
P a g e 6 | 18
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
One Liners: Programing Fundamentals
1. At its core, a computer processes information using two states: ON (1) and OFF (0).
2. The binary number system has a base of 2 and uses only the digits 0 and 1.
3. A Bit (Binary Digit) is the smallest unit of data, holding a value of either 0 or 1.
4. A Byte is a group of 8 bits and is the standard unit for measuring data size.
M 7. To convert binary to decimal, use positional notation: multiply each bit by 2 raised to its position
power and sum the results.
8. To convert decimal to binary, use the repeated division-by-2 method and read the remainders from
K the last to the first.
9. ASCII is an 8-bit code representing 128 characters, where 'a' = 01100001₂ (97₁₀).
10. Unicode is an extended system capable of representing over 65,000 characters from many world
languages.
P 11. In the RGB color model, each color component (Red, Green, Blue) is represented by an 8-bit
number (0-255).
R 12.
13.
White in RGB is represented as (255,255,255) or (11111111, 11111111, 11111111)₂.
Sound is converted from analogue to digital using an Analogue-to-Digital Converter (ADC).
E 14. The quality of digital sound is determined by Sample Rate (samples per second) and Bit Depth (bits
per sample).
15. Problem analysis involves clearly defining the problem, identifying causes, and brainstorming
P solutions.
16. Solution planning techniques include Abstraction, Divide and Conquer, Analogy, Brainstorming,
A 17.
and Research.
The best solution is evaluated based on Speed/Time Efficiency, Cost (resources, memory), and
R 18.
Complexity (number of steps).
An algorithm is a well-defined, step-by-step procedure that takes input, processes it, and produces
A 19.
an output.
Algorithm efficiency is measured by Time Complexity (execution speed) and Space Complexity
T 20.
(memory usage).
A flowchart is a diagrammatic representation of an algorithm using standardized symbols.
21. In a flowchart, an Oval represents the Start or End terminal.
I 22. In a flowchart, a Parallelogram represents an Input or Output operation.
23. In a flowchart, a Rectangle represents a Process or calculation step.
O 24.
25.
In a flowchart, a Diamond represents a Decision point (Yes/No, True/False).
Before drawing a flowchart, determine the problem's inputs, processing, decisions, and outputs.
N 26.
27.
A Program is a set of ordered instructions telling a computer how to perform a specific task.
The concept of a stored program in memory was pioneered by John von Neumann.
S 28.
29.
Software is a collection of many programs bundled together for a larger task (e.g., Microsoft Paint).
Programming is the process of designing, writing, testing, and maintaining source code.
30. Machine Language is the computer's native language of 1s and 0s; it is machine-dependent and
difficult for humans.
31. Assembly Language uses simple abbreviations (mnemonics) and requires an assembler.
32. High-Level Languages (e.g., Python, C++) use English-like syntax and require a compiler or
interpreter.
P a g e 10 | 18
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Practice MCQs
1. Which of the following correctly defines the d) Decision or Conditional branch
relationship between a bit and a byte? Answer: d) Decision or Conditional
a) A bit is a group of 8 bytes. branch
b) A byte is a group of 8 bits. 7. The von Neumann architecture is most
E 29 is:
a) 11100
block of code to be executed repeatedly as
long as a condition remains true is a:
b) 11101 a) Sequence
P c) 11011 b) Selection
d) 10111 c) Loop (Repetition)
A Answer: b) 11101
4. In the RGB color model, the binary
d) Event
Answer: c) Loop (Repetition)
R representation for the color Red (255, 0, 0)
would be:
10. In Scratch, a variable declared as "for this
sprite only" has what kind of scope?
A a) (11111111, 00000000, 00000000)
b) (00000000, 11111111, 00000000)
a) Global scope
b) Local scope
P • The assignment operator returns the value assigned. This allows chained assignment: a = b
= c = 5; (all get the value 5).
M }
sum += i;
P }
printf("\n"); // New line after each row
A /* Output:
*
**
R ***
****
A *****
*/
P a g e 21 | 77
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
c
#include <stdio.h>
#include <string.h>
int main() {
// Output
printf("Hello, %s\n", name);
P return 0;
R }
Common String Functions (string.h):
E
c
#include <string.h>
P char
char
str1[20] = "Hello";
str2[20] = "World";
A char
char
str3[40];
str4[] = "Hello, World!";
N
int result = strcmp("apple", "banana"); // Negative (apple < banana)
result = strcmp("apple", "apple"); // 0 (equal)
result = strcmp("banana", "apple"); // Positive (banana > apple)
S // strncpy(), strncat(), strncmp(): Safer versions with length limit
char dest[10];
strncpy(dest, "Hello, World!", 9);
dest[9] = '\0'; // Ensure null-termination
P a g e 33 | 77
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
One Liners: Programing Fundamentals & Coe Concepts
Programming Fundamentals & Binary System
1. The binary number system uses only two digits: 0 and 1, representing the OFF and ON states of a
computer.
M 6.
Significant Bit (LSB).
Binary to decimal conversion uses positional notation: each bit is multiplied by 2 raised to its position
power.
K 7. Decimal to binary conversion uses the repeated division-by-2 method, reading remainders from last to
first.
8. ASCII is an 8-bit character encoding standard representing 128 characters, with 'A' = 65 and 'a' = 97.
9. Unicode extends ASCII to support over 65,000 characters from multiple writing systems worldwide.
P 10. In the RGB color model, each color component (Red, Green, Blue) is represented by an 8-bit value
from 0 to 255.
R 11.
12.
White in RGB is (255,255,255) or binary 11111111 for each component.
Digital sound conversion uses an Analogue-to-Digital Converter (ADC), with quality determined by
E
sample rate and bit depth.
13. Problem analysis involves defining the problem clearly, identifying causes, and brainstorming
solutions.
P 14. Abstraction in problem-solving means creating a simplified model focusing only on essential details.
15. Divide and conquer breaks complex problems into smaller, more manageable sub-problems.
A 16.
17.
An algorithm is a finite, step-by-step procedure that takes input, processes it, and produces output.
Algorithm efficiency is measured by time complexity (execution speed) and space complexity
R 18.
(memory usage).
A flowchart's diamond shape represents a decision point with yes/no or true/false branches.
A 19.
20.
The parallelogram in a flowchart denotes input/output operations.
John von Neumann pioneered the stored-program concept where both instructions and data reside in
memory.
T 21. Software is a collection of multiple programs bundled together for a comprehensive task.
22. Machine language (1GL) consists of binary code (0s and 1s) executed directly by the CPU.
I 23. Assembly language (2GL) uses mnemonics like ADD and MOV, requiring an assembler for
translation.
O 24.
25.
High-level languages (3GL) like C and Python use English-like syntax and are machine-independent.
Procedural languages design programs as sequences of procedures operating on data.
N 26.
27.
Object-oriented languages model programs as collections of interacting objects.
A compiler translates the entire source program into machine code in one go.
S 28.
29.
An interpreter translates and executes code line by line, stopping at errors.
The five fundamental programming constructs are sequence, selection, repetition, events, and
variables/constants.
30. Syntax errors violate language grammar rules and prevent program execution.
31. Logical errors allow programs to run but produce incorrect results due to flawed logic.
32. In Scratch, variables can be "for this sprite only" (local) or "for all sprites" (global).
33. Scratch's forever block creates an infinite loop, while repeat [n] executes a block n times.
34. Python uses dynamic typing where variable types are inferred from assigned values.
35. Python's input() function reads strings, requiring explicit conversion (e.g., int()) for numeric input.
36. The // operator in Python performs floor division, returning the integer quotient.
37. Python lists are ordered, mutable collections accessed via zero-based indexing.
38. The append() method adds an element to the end of a Python list.
39. A webpage is a single HTML document, while a website is a collection of related webpages.
40. A web server hosts websites and serves requested pages to client browsers.
P a g e 59 | 77
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Practice MCQs
1. In the binary number 110101, what is c) Graphical user interface
the decimal value of the most significant bit? d) Object-oriented programming
M Answer: c) 32
2. When converting decimal 45 to binary
a) Compiler
b) Assembler
using repeated division-by-2, what is the c) Interpreter
K sequence of remainders read from last to d) Linker
first? Answer: c) Interpreter
a) 101101 9. A program runs but produces incorrect
b) 1011011 output. This is most likely a:
P c) 1011010
d) 101101
a) Syntax error
b) Semantic error
R Answer: a) 101101
3. Which statement about ASCII encoding
c) Logical error
d) Runtime error
E
is INCORRECT? Answer: c) Logical error
a) It uses 8 bits per character 10. In Scratch, a variable declared as "for
b) It represents 256 different characters this sprite only" has:
P c) 'a' has decimal value 97 a) Global scope
d) Uppercase letters come before lowercase in b) Local scope
A value
Answer: b) It represents 256 different
c) Static scope
d) Dynamic scope
R characters
4. In the RGB color model, what is the
Answer: b) Local scope
11. What will be the output of Python code:
A binary representation for pure green?
a) 00000000 11111111 00000000
print(7 // 2)?
a) 3.5
b) 11111111 00000000 00000000 b) 3
T c) 00000000 00000000 11111111 c) 4
d) 11111111 11111111 00000000 d) 3.0
I Answer: a) 00000000 11111111 00000000 Answer: b) 3
5. Which problem-solving technique 12. The Python range(5, 0, -2) generates:
O involves ignoring unnecessary details to
focus on the core model?
a) 5, 3, 1
b) 5, 4, 3, 2, 1
N a) Decomposition
b) Pattern Recognition
c) 0, 1, 2, 3, 4
d) 5, 4, 3, 2, 1, 0
S c) Abstraction
d) Algorithmic Design
Answer: a) 5, 3, 1
13. Which Python method correctly adds
Answer: c) Abstraction 'cherry' to the end of a list named fruits?
6. What is the primary purpose of a a) [Link]('cherry')
flowchart's diamond-shaped symbol? b) [Link]('cherry')
a) Start/End point c) [Link]('cherry')
b) Input/Output operation d) [Link]('cherry')
c) Process/Calculation step Answer: b) [Link]('cherry')
d) Decision/Conditional branch 14. A website that changes content based on
Answer: d) Decision/Conditional branch user input without reloading the page is best
7. The von Neumann architecture is described as:
revolutionary because it introduced: a) A static website
a) Binary number system b) A responsive website
b) Stored-program concept c) A dynamic website
P a g e 64 | 77
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Chapter 17
K • Web: A collection of interconnected documents (web pages) accessed via web browsers.
The Web operates on a client-server model, where browsers (clients) request resources from web
servers, which respond with the requested content, typically in HTML format.
What is Web Development?
Web Development is the process of creating websites and web applications. It involves designing,
P building, and maintaining sites using a combination of programming languages, frameworks, and tools. Web
development is broadly categorized into:
R 1. Front-End Development: Concerned with what users see and interact with (user interface).
2. Back-End Development: Deals with server-side logic, databases, and application functionality.
E 3. Full-Stack Development: Combines both front-end and back-end expertise.
1.3 Why Learn Web Development?
P • Digital Literacy: Understanding how websites are built and how the Internet works.
• Career Opportunities: Opens roles such as Web Developer, UI/UX Designer, Front-End/Back-End
S • URL (Uniform Resource Locator): The unique address of a resource on the Internet.
Format: protocol://hostname/path. Example: [Link]
• Search Engine: A website that helps users find information by searching keywords (e.g., Google,
Bing).
• Home Page: The main or index page of a website, usually the first page accessed.
• Web Hosting: A service that stores website files on a server connected to the Internet, making them
accessible worldwide.
Types of Websites
1. Web Portals: Comprehensive sites offering multiple services (email, news, search) often requiring
login (e.g., university portals).
2. News Websites: Provide latest news, updates, videos, and archives (e.g., BBC, Tribune).
3. Informational Websites: Offer detailed information on various topics (e.g., Wikipedia).
P a g e 1 | 29
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
php
<!DOCTYPE html>
<html>
<body>
<h1>My PHP Page</h1>
R $dbname = "myDB";
A while($row = mysqli_fetch_assoc($result)) {
echo "ID: " . $row["id"] . " - Name: " . $row["name"] . "<br>";
T }
mysqli_close($conn);
I ?>
Security Note: Always use prepared statements to prevent SQL injection.
O HTTP Protocol and Request-Response Cycle
HTTP is a stateless application-layer protocol.
N • HTTP Request: Sent from browser to server. Contains method (GET, POST), headers, and optional
body.
S • HTTP Response: Sent from server to browser. Contains status code (200 OK, 404 Not Found),
headers, and body (HTML, JSON, etc.).
Advanced Web Concepts
AJAX (Asynchronous JavaScript and XML)
AJAX allows web pages to communicate with a server asynchronously without reloading.
Example using fetch():
javascript
fetch('get_data.php')
.then(response => [Link]())
.then(data => {
[Link](data);
// Update DOM with data
P a g e 8 | 29
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
One Liners: We Development & Web Programing
Web Fundamentals & Terminology (1-25)
1. Tim Berners-Lee introduced the World Wide Web to the public on August 6, 1991.
2. The Internet is the global network connecting computers, while the Web is the collection of
M 6. URL stands for Uniform Resource Locator and follows the format:
protocol://hostname/other_information.
7. The home page is the main or index page of a website that opens first when the site is accessed.
K 8. Web hosting is the service of storing website content on a server connected to the Internet.
9. Search engines like Google help users find information by searching keywords across the Web.
10. Web portals are comprehensive websites offering multiple services like email and news, often
requiring login.
P 11. Front-end development focuses on what users see and interact with, using HTML, CSS, and
JavaScript.
R 12. Back-end development manages behind-the-scenes functionality like servers, databases, and
application logic.
E
13. Full-stack development involves both front-end and back-end aspects of web application
development.
14. Digital literacy through web development helps understand how websites are built and how the
P Internet works.
15. Career opportunities in web development include roles like web developer, designer, and other IT
A industry positions.
16. Web development enhances problem-solving skills through logical thinking and troubleshooting.
R 17. Web development allows creativity by enabling the creation of visually appealing and interactive
websites.
A 18. Entrepreneurship skills are supported by web development through starting online businesses or web
services.
19. A web browser is software used to retrieve and display information from websites.
T 20. HTTP (Hypertext Transfer Protocol) is used by web servers to deliver web pages to users' browsers.
21. News websites provide the latest news, updates, and often include videos and archives.
I 22. Informational websites like Wikipedia provide detailed information on various topics.
23. Educational websites are created for learning, offering tutorials, courses, and organized educational
O content.
24. Personal websites are created by individuals for expression, portfolio, or social networking.
N 25. Business websites facilitate business activities like e-commerce, banking, and reservations.
HTML Fundamentals (26-75)
S 26. HTML (HyperText Markup Language) is the standard markup language for creating web pages.
27. HTML 1.0 was the first, simple version released in 1991.
28. HTML 2.0 introduced more tags for complex pages in 1995.
29. HTML 3.2 added tags for tables, scripts, and applets in 1997.
30. HTML 4.0/4.01 brought major improvements with support for multimedia in 1997/1999.
31. HTML5 is the latest version with new elements for better multimedia, graphics, and interactivity,
released in 2014.
32. HTML files are saved with a .html extension, such as [Link].
33. The basic structure of an HTML5 document starts with <!DOCTYPE html> declaration.
34. The <html> tag is the root element of an HTML page.
35. The <head> section contains meta-information like the page title and links to CSS/JavaScript.
36. The <title> tag sets the title shown in the browser tab.
37. The <body> tag contains the visible page content like headings, paragraphs, and images.
P a g e 10 | 29
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Practice MCQs
1. Which of the following correctly distinguishes 7. Which HTML version first introduced
between the Internet and the World Wide Web? support for tables and scripts?
A) The Internet is for emails, while the Web is for A) HTML 1.0
E
Answer: B C) <h1> ... </h1>
3. What is the significance of August 6, 1991, in D) <caption> ... </caption>
the context of web development? Answer: B
P A) The day JavaScript was created by Brendan 10. What is the key difference between paired
Eich tags and unpaired tags in HTML?
A B) The day the first web browser was released
C) The day Tim Berners-Lee introduced the World
A) Paired tags have semantic meaning, while
unpaired tags don't
R Wide Web to the public
D) The day HTML5 specification was finalized
B) Paired tags require closing tags, while unpaired
tags are self-closing
A Answer: C
4. Which type of website typically requires user
C) Paired tags are for content, while unpaired tags
are for styling
login and offers multiple integrated services like D) Paired tags are HTML5 only, while unpaired
T email and news? tags are older HTML
A) News Website Answer: B
I B) Web Portal 11. Which heading tag represents the most
C) Personal Website important heading on a page?
O D) Entertainment Website
Answer: B
A) <h1>
B) <h3>
N 5. In the URL
"[Link]
C) <h6>
D) <header>
P a g e 17 | 29
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Chapter 18
T • Intensive Coding & Difficult Data Access: Separate programs were needed for each task, and
retrieving information required extensive programming.
What is a Database?
I A database is a shared, integrated, and logically related collection of data, along with a description of
that data (metadata). It is designed to meet the information needs of multiple users in an organization. A
O key principle is that data in a database is independent of the application programs that use it.
Database Management System (DBMS)
N A DBMS is a set of software programs that enables users to create, maintain, manipulate, and
access a database. Manipulation includes adding, deleting, and changing data. Popular examples
S include Microsoft Access, Oracle, MySQL, Microsoft SQL Server, and IBM DB2.
Advantages of DBMS over FMS:
1. Controlled Data Redundancy: Data is stored logically only once.
2. Data Consistency: Minimal redundancy ensures uniform data.
3. Data Sharing: A centralized resource accessible by authorized users.
4. Enforcement of Standards: Centralized control enforces naming, format, and structure standards.
5. Enhanced Security: Permissions and access controls are centralized.
6. Reduced Program Maintenance: DBMS tools simplify development.
P a g e 1 | 20
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
93. Transitive Dependency is a functional dependency between two or more non-key attributes (e.g.,
CUSTNO → SALESMAN and SALESMAN → REGION).
94. An Insertion Anomaly is the inability to add data without other, unrelated data.
95. A Deletion Anomaly is the unintended loss of data when deleting a record.
96. An Update Anomaly is inconsistency from updating some, but not all, copies of redundant data.
P
and manipulate data.
103. Data Control Language (DCL) commands (GRANT, REVOKE) control access.
104. Views are virtual tables created using SQL (CREATE VIEW) that provide a customized, secure
R subset of data.
105. Data Analytics examines raw data to draw conclusions, answer specific questions, and identify
E 106.
trends.
Data Science is a broader, interdisciplinary field using mathematics, statistics, ML, and
P 107.
programming to extract knowledge from data.
Qualitative (Categorical) Data includes Nominal (no inherent order) and Ordinal (meaningful order)
A 108.
data.
Quantitative (Numerical) Data includes Discrete (countable) and Continuous (measurable within a
range) data.
R 109. Continuous data can be Interval (differences meaningful, no true zero) or Ratio (differences
meaningful, has a true zero).
A 110. Primary Data is collected firsthand (surveys, experiments, sensors).
111. Secondary Data is collected by others (published sources, online databases).
T 112.
113.
Relational (SQL) databases (e.g., MySQL, MS Access) are used for structured data.
Non-Relational (NoSQL) databases (e.g., MongoDB) are used for semi/unstructured data.
I 114. Artificial Intelligence (AI) refers to machines mimicking human intelligence (problem-solving,
language understanding).
O 115. Machine Learning (ML) is a subset of AI where systems learn from data without explicit
programming.
116. Supervised Learning uses labeled datasets (input-output pairs) for tasks like classification and
N regression.
117. Unsupervised Learning finds patterns in unlabeled datasets for tasks like clustering and association.
S 118. Reinforcement Learning involves an agent learning by interacting with an environment, receiving
rewards/penalties.
119. Feature Engineering is the process of selecting and transforming relevant data attributes for ML
models.
120. Training Data is used to teach an ML model; Test Data is used to evaluate it.
121. Overfitting occurs when a model learns training data too well, including noise, and performs poorly
on new data.
P a g e 13 | 20
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Practice MCQs
1. What is the primary difference between D) NULL Allowed
data and information? Answer: C) No Duplicate Rows
A) Data is processed; information is raw 7. What is a set of one or more attributes
B) Data is meaningful on its own; information that can uniquely identify all other
R D) Enhanced Security
Answer: C) Data Inconsistency
Answer: D) Primary Key
9. What does a Foreign Key (FK) enforce
3. What is the key principle that data in a between tables?
E database is independent of the application A) Entity Integrity
programs called? B) Referential Integrity
P A) Data Redundancy
B) Program-Data Dependence
C) Column Atomicity
D) Data Redundancy
A C) Data Isolation
D) Program-Data Independence
Answer: B) Referential Integrity
10. In an ER diagram, what does a diamond
R Answer: D) Program-Data Independence
4. Which database model allows a child
represent?
A) Entity
K builder with an intuitive programming language based on the original BASIC syntax. The name itself is
descriptive: “Visual” refers to the visual method of designing user interfaces, and “Basic” stands
for Beginner’s All-purpose Symbolic Instruction Code.
Visual Basic follows the event-driven programming paradigm, meaning programs are structured
around user actions such as mouse clicks, key presses, or system events. It also supports Rapid Application
P Development (RAD), allowing developers to quickly prototype and build applications using pre-built,
reusable components.
R Detailed Characteristics
1. High-Level Language
E VB uses English-like syntax, abstracting away low-level hardware details. This makes it accessible to
beginners while remaining powerful enough for complex applications.
P 2. Event-Driven Programming Model
Programs are composed of event handlers—blocks of code that execute in response to specific user or
system events.
A 3. RAD Environment
Developers can drag controls from a toolbox onto forms, set properties in a visual designer, and write
R code only for the events they need to handle.
4. Hybrid Execution Model
A VB6 used a P-code interpreter, while [Link] compiles to Microsoft Intermediate Language
(MSIL), which is then Just-In-Time (JIT) compiled to native code.
T Historical Evolution and Context
Visual Basic has evolved significantly since its introduction:
I • VB 1.0 (1991)
Introduced the revolutionary drag-and-drop interface builder, eliminating the need for complex
Windows API calls to create user interfaces.
O • VB 3.0 (1993)
Added built-in database access via the Jet Engine, transforming VB into a serious tool for business
N application development.
• VB 6.0 (1998)
S Became the most popular version, with enhanced web capabilities and widespread adoption in
enterprise environments. It remains in use in many legacy systems.
• [Link] (2002)
A complete rewrite for the .NET Framework, marking a shift from the COM-based architecture to the
managed, object-oriented .NET platform.
VB6 vs [Link]: The Fundamental Shift
Definition of the Shift
VB6 was the final version based on the Component Object Model (COM), while [Link] is the first .NET-
based version, built from the ground up to leverage the .NET Framework’s capabilities.
Why the Shift Was Necessary
1. Full Object-Oriented Support
VB6 offered limited OOP features; [Link] provides full inheritance, polymorphism, and
encapsulation.
P a g e 1 | 39
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Select Case Statement
An efficient alternative to long If-ElseIf chains when testing a single variable against multiple discrete
values.
vb
Select Case dayNumber
P
[Link](i) ' Counts down
Next
P a g e 7 | 39
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
One Liners: Visual Basic for Applications & .NET Framework
1. Visual Basic is a third-generation, high-level programming language that follows the event-driven
paradigm and supports Rapid Application Development (RAD).
2. The "Visual" in Visual Basic refers to the visual method of creating user interfaces through drag-and-
M 5.
events rather than following a linear execution path.
Rapid Application Development (RAD) in VB enables quick prototyping through reusable
components and visual design tools.
K 6. VB6 used P-code interpretation, while [Link] uses full compilation to Microsoft Intermediate
Language (MSIL).
7. VB 1.0 (1991) revolutionized Windows programming by eliminating complex Windows API calls for
UI creation through drag-and-drop interface building.
P 8. VB 3.0 (1993) became a serious business application development tool after adding database access
through the Jet Engine.
R 9. VB 6.0 (1998) remains in use in legacy systems and represents the peak of COM-based Visual Basic
development.
E
10. [Link] (2002) was a complete rewrite for the .NET Framework, shifting from COM to managed
.NET architecture.
11. The fundamental shift from VB6 to [Link] was necessary because VB6 lacked full object-oriented
P programming support.
12. .NET Framework offers cross-language compatibility, allowing [Link] to interoperate seamlessly
A 13.
with C#, F#, and other .NET languages.
.NET provides code access security, a significant improvement over VB6's limited security model.
R 14. Automatic garbage collection in .NET eliminates manual memory management and prevents memory
leaks common in VB6.
A 15. VB6 uses Variant data type by default, allowing implicit type conversions that can cause runtime
errors.
16. [Link] with Option Strict On requires explicit type conversions, preventing type-related bugs at
T compile time.
17. VB6 uses unstructured error handling with On Error GoTo, which creates spaghetti code and makes
I 18.
program flow difficult to follow.
[Link] uses structured exception handling with Try-Catch-Finally blocks, providing readable error
O 19.
handling with specific exception types.
The Finally block in [Link] executes cleanup code regardless of whether an exception occurs or
N 20.
not.
.NET Framework is a software development platform that provides a controlled programming
S 21.
environment for [Link] applications.
The four-layer .NET architecture consists of: VB Application, VB Language, Common Language
Runtime (CLR), and Base Class Library (BCL).
22. Common Language Runtime (CLR) is the execution engine that manages running .NET applications
through services like JIT compilation and garbage collection.
23. Just-In-Time (JIT) compilation converts MSIL to native machine code at runtime for optimal
performance.
24. Base Class Library (BCL) provides pre-built classes for common functionality like file operations
([Link]) and database access ([Link]).
25. The complete flow in .NET is: VB Code → MSIL → CLR loading → JIT compilation → Native code
execution.
26. Integrated Development Environment (IDE) provides comprehensive facilities including code editor,
debugger, and design tools in a single application.
P a g e 17 | 39
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Practice MCQs
1. What fundamentally visual design tools
distinguishes [Link] from VB6 in C) Through built-in artificial intelligence
M .NET-based
C) [Link] is .NET-based while VB6 is
6. What execution model did VB6 use that
differed from [Link]'s approach?
COM-based A) VB6 used native compilation
K D) [Link] is interpreted while VB6 is while [Link] uses interpretation
compiled B) VB6 used P-code interpretation
Answer: C (The architectural shift from while [Link] compiles to MSIL
COM to .NET is the fundamental C) VB6 used JIT compilation
P difference)
2. Why was the shift from VB6
while [Link] uses ahead-of-time
compilation
R to [Link] considered necessary despite
VB6's popularity?
D) Both used identical execution models
Answer: B (P-code vs MSIL/JIT
E
A) VB6 lacked graphical interface compilation distinguishes the execution
capabilities models)
B) VB6 was incompatible with Windows 7. Which version of VB is still commonly
P operating systems found in legacy enterprise systems?
C) VB6 lacked full object-oriented A) VB 1.0
A programming support
D) VB6 couldn't connect to databases
B) VB 3.0
C) VB 6.0
R Answer: C (Limited OOP was a key
driver for the architectural rewrite)
D) [Link] 2002
Answer: C (VB6 remains in many legacy
A 3. Which feature introduced in VB 3.0
transformed it into a serious business 8.
systems despite being obsolete)
What was the revolutionary aspect of
application development tool? VB 1.0 that changed Windows
T A) Web capabilities through ActiveX programming?
B) Database access via Jet Engine A) It introduced object-oriented
I C) Drag-and-drop interface creation
D) Full OOP support
programming to Windows
B) It eliminated complex Windows API
O Answer: B (Jet Engine database access
made VB viable for business applications)
calls for UI creation
C) It was the first interpreted language for
N 4. What does the "Visual" in Visual Basic
specifically refer to?
Windows
D) It introduced database programming to
P a g e 23 | 39
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Chapter 20
Oracle Database & PL/SQL
Introduction to Oracle Database
What is Oracle Database?
A money:
1. System checks balance (SELECT query)
2. Deducts amount (UPDATE query)
R 3. Logs transaction (INSERT into transactions table)
4. All three steps succeed or fail together as a transaction – ensuring data consistency.
A Technical Illustration:
sql
T CREATE TABLE customers (
customer_id NUMBER PRIMARY KEY,
I name VARCHAR2(50),
account_number VARCHAR2(20) UNIQUE,
O );
balance NUMBER(10,2) CHECK(balance >= 0)
S Oracle Architecture
Oracle’s architecture is divided into two main components: the instance (memory and processes) and
the database (physical files). This separation allows efficient management of memory, processes, and storage.
Instance Components
An Oracle instance consists of memory structures (SGA) and background processes.
A. System Global Area (SGA) – Shared memory region:
• Database Buffer Cache: Caches data blocks read from datafiles.
• Redo Log Buffer: Stores changes before they are written to redo log files.
• Shared Pool: Caches SQL statements (library cache) and data dictionary information (row cache).
• Large Pool & Java Pool: Optional memory areas for specific operations.
B. Background Processes:
• PMON (Process Monitor): Cleans up failed user processes and releases resources.
• SMON (System Monitor): Performs crash recovery, cleans temporary segments.
P a g e 1 | 36
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
BEGIN
SELECT * INTO v_employee FROM employees WHERE employee_id = 9999;
v_salary := v_employee.salary / 0;
T BEGIN
v_value NUMBER;
M 7.
8.
Oracle provides advanced security via authentication, authorization, auditing, and encryption.
Performance features in Oracle include query optimization, indexing, caching, and partitioning.
9. Oracle supports enterprise features like data warehousing, replication, and advanced analytics.
K 10. A transaction in Oracle ensures all steps succeed or fail together, maintaining data consistency.
11. Oracle architecture comprises two main components: the instance (memory and processes) and the
database (physical files).
12. The System Global Area (SGA) is a shared memory region containing the buffer cache, redo log
P 13.
buffer, and shared pool.
The Database Buffer Cache stores data blocks read from datafiles.
R 14.
15.
The Redo Log Buffer holds changes before they are written to redo log files.
The Shared Pool caches SQL statements and data dictionary information.
E
16. Background processes in Oracle include PMON, SMON, DBWn, LGWR, and CKPT.
17. PMON (Process Monitor) cleans up failed user processes and releases resources.
18. SMON (System Monitor) performs crash recovery and cleans temporary segments.
P 19. DBWn (Database Writer) writes modified buffers from the buffer cache to datafiles.
20. LGWR (Log Writer) writes redo log buffer entries to redo log files.
A 21.
22.
CKPT (Checkpoint Process) updates control files and datafile headers with checkpoint information.
Physical files in Oracle include datafiles, control files, redo log files, and parameter files.
R 23. The flow of a SELECT query involves the shared pool check, buffer cache check, and possible disk
I/O.
A 24.
25.
Logical storage hierarchy in Oracle: Database → Tablespace → Segment → Extent → Block.
Physical storage hierarchy: Database → Datafile → OS Block → Disk Sector.
26. A tablespace is a logical storage unit containing segments like tables and indexes.
T 27. An extent is a contiguous set of database blocks allocated to a segment.
28. The smallest unit of I/O in Oracle is a database block (default 8KB).
I 29. CHAR(n) is fixed-length and padded with spaces; VARCHAR2(n) is variable-length with no padding.
30. NCHAR and NVARCHAR2 support Unicode for multilingual data.
O 31.
32.
NUMBER(p,s) stores numeric data with precision p and scale s.
DATE stores date and time to the second; TIMESTAMP includes fractional seconds.
N 33.
34.
LOB types include CLOB for text, BLOB for binary data, and BFILE for external files.
DDL commands (CREATE, ALTER, DROP, TRUNCATE, RENAME) auto-commit transactions.
S 35.
36.
DML commands (SELECT, INSERT, UPDATE, DELETE, MERGE) require explicit commit.
DCL commands (GRANT, REVOKE) manage privileges and roles.
37. TCL commands (COMMIT, ROLLBACK, SAVEPOINT) manage transaction boundaries.
38. Analytic functions perform calculations across a set of rows related to the current row.
39. Hierarchical queries retrieve tree-structured data using CONNECT BY and START WITH.
40. Flashback queries retrieve data as it existed at a previous point in time.
41. The MERGE statement performs conditional insert or update (UPSERT).
42. PIVOT transforms row data into columnar format; UNPIVOT does the reverse.
43. Oracle’s advanced SQL features support complex business scenarios like monthly comparisons and
ETL processes.
Volume II: PL/SQL Programming
44. PL/SQL is Oracle’s procedural extension to SQL, enabling complex logic within the database.
45. PL/SQL reduces network traffic by executing multiple SQL statements in a single block.
P a g e 20 | 36
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Practice MCQs
1. Which of the following best describes c) Performing checkpoints
Oracle Database? d) Writing datafiles
a) A file-based storage system Answer: b) Cleaning up failed user
M RDBMS
2. ACID properties in Oracle ensure:
c) Shared pool, buffer cache
d) Datafiles, control files
a) High availability and redundancy Answer: b) Redo log buffer, redo log
K b) Atomicity, Consistency, Isolation, files
Durability 9. The physical file that contains database
c) Fast backup and recovery structure metadata is:
d) Data encryption and compression a) Datafile
P Answer: b) Atomicity, Consistency,
Isolation, Durability
b) Control file
c) Redo log file
R 3. Oracle’s client-server architecture
enables:
d) Parameter file
Answer: b) Control file
E
a) Single-user access only 10. During a SELECT query, if parsed SQL
b) Concurrent access with locking is found in the shared pool, it results in:
mechanisms a) Hard parsing
P c) Only read operations b) Soft parsing
d) No network connectivity c) No parsing
A Answer: b) Concurrent access with
locking mechanisms
d) Recompilation
Answer: b) Soft parsing
R 4. Which feature allows Oracle to handle
terabytes of data?
11. The logical storage unit containing
segments is called:
A a) Scalability
b) Encryption
a) Database
b) Tablespace
c) Auditing c) Extent
T d) Graphical interface d) Block
Answer: a) Scalability Answer: b) Tablespace
I 5. High availability in Oracle is achieved 12. The smallest unit of I/O in Oracle is:
through: a) Extent
O a) Failover and redundancy mechanisms
b) Only backup files
b) Segment
c) Block
N c) Single server setup
d) Manual intervention
d) Tablespace
Answer: c) Block
P a g e 23 | 36
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Chapter 21
A
1. Phased Development: It breaks down the complex software development lifecycle into manageable
phases, making it easier for team members to evaluate each part.
2. Concurrent Work: It enables programmers and other specialists to work concurrently on different
R phases, improving efficiency.
3. Time Estimation: It provides a framework for estimating when the software will be available for use.
A 4. Quality Assurance: It ensures the delivery of quality software that meets or exceeds customer
expectations by providing a structured framework.
T 5. Project Management: It helps project managers establish a clear management structure to be
followed strictly during development.
I 6.
7.
Role Definition: It clearly defines and assigns the roles and responsibilities of all involved parties.
Requirement Clarity: It ensures that the requirements for the software system are well-defined and
subsequently satisfied.
O Objectives of SDLC
N •
The primary objectives of the SDLC are to:
Deliver high-quality software that meets customer expectations.
• Deliver cost-effective and easily maintainable software.
S • Maximize productivity in terms of software systems delivered.
• Establish an appropriate level of management authority to direct, coordinate, control, review, and
approve the project.
• Ensure project management accountability.
• Facilitate proper documentation of all development requirements.
• Ensure projects are developed within the current and planned IT infrastructure.
• Identify potential project risks in advance to allow for proper mitigation planning.
P a g e 1 | 22
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
One Liners: System Development Troubleshooting and
Maintenance
A 12. Effective troubleshooting can reveal security vulnerabilities and breaches, allowing for swift
protective action.
13. Troubleshooting enhances system performance by identifying causes of slowdowns, such as
R insufficient RAM or software conflicts.
14. Regular troubleshooting and fixing small issues early can extend equipment life by preventing
A 15.
major failures.
Mastering troubleshooting saves costs by reducing the need for expensive emergency repairs and
T 16.
prolonged downtime.
A reliable, well-performing system resulting from good troubleshooting enhances the overall user
I 17.
experience.
For an application freezing, a common solution is to use Task Manager (Ctrl+Alt+Delete) to end
O 18.
the unresponsive task.
If an application freezing persists, reinstalling the application or checking for updates is
recommended.
N 19. For unresponsive peripherals, the first steps are to check physical connections and unplug/replug
the device.
S 20.
21.
Updating device drivers is a standard solution for resolving issues with unresponsive peripherals.
Restarting a computer clears memory and stops conflicting processes, fixing a significant
percentage of software issues.
22. As a last resort for an unresponsive system, pressing and holding the power button forces a
shutdown but should be used cautiously to avoid data loss.
23. Loose or disconnected cables are a common hardware culprit, and securing all connections is a
primary solution.
P a g e 11 | 22
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Practice MCQs
1. What is the primary goal of system 6. An application becomes unresponsive.
P a g e 17 | 22
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Chapter 22
System Analysis and Design
Foundations of System Analysis & Design
K Explanation:
• A system has boundaries separating it from its environment.
• It accepts inputs from outside, processes them through defined procedures, and
produces outputs.
P • It operates within an environment and interacts with it.
Example: A university admission system.
R • Inputs: Student applications, marks, fees.
• Processing: Eligibility checks, merit calculation, seat allocation.
E • Outputs: Admission lists, fee receipts, roll numbers.
• Environment: Educational policy, competition, technological infrastructure.
P Summary: A system is a goal-oriented collection of interrelated components working together.
Characteristics of a System
A 1. Organization: Structured arrangement of components.
P a g e 1 | 38
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
One Liners: System Analysis and Design
1. System: A set of interrelated components working toward a common objective.
2. Information System: A formal system to collect, process, store, and distribute information.
3. SDLC: Framework of phases to develop systems systematically.
M 7.
8.
Technical Feasibility: Can the system be built with available technology?
Economic Feasibility: Cost-benefit analysis; ROI, payback period.
K 9.
10.
Operational Feasibility: Will the system be used effectively?
Functional Requirements: What the system must do.
11. Non-functional Requirements: How well the system performs (speed, security).
12. JAD: Joint Application Development – intensive workshop for requirements.
P 13.
14.
DFD: Data Flow Diagram – shows movement of data through processes.
Context Diagram: Highest-level DFD with single process.
R 15. Entity: A person, place, thing, or event about which data is stored.
16. Cardinality: Number of instances one entity can associate with another.
E 17. Normalization: Process of organizing data to minimize redundancy.
18. 1NF: Eliminate repeating groups; atomic values.
P 19. 2NF: In 1NF + no partial dependency (all non-key attributes depend on full primary key).
20. 3NF: In 2NF + no transitive dependency.
A 21. Cohesion: Measure of how closely operations in a module are related.
Coupling: Degree of interdependence between modules (low coupling desired).
R
22.
23. Black-box Testing: Tests functionality without knowing internal logic.
A 24.
25.
White-box Testing: Tests internal structures or workings.
Alpha Testing: By development team within organization.
T 26.
27.
Beta Testing: By actual users in real environment.
Regression Testing: Re-testing after modifications to ensure no new bugs.
I 28.
29.
System Maintenance: Modifying system after deployment.
Corrective Maintenance: Fixing defects.
O 30.
31.
Adaptive Maintenance: Adapting to new environment (OS, hardware).
Perfective Maintenance: Improving performance, adding minor features.
N 32.
33.
Preventive Maintenance: Preventing future problems.
Agile: Iterative, incremental, flexible development methodology.
S 34. Scrum: Agile framework with sprints, product owner, scrum master.
35. UML: Unified Modeling Language – standard for OO modeling.
36. Use Case Diagram: Shows actors and use cases (functionality).
37. Class Diagram: Static structure – classes, attributes, methods, relationships.
38. Sequence Diagram: Shows object interactions over time.
39. CASE Tools: Computer-Aided Software Engineering – automate SDLC activities.
40. Data Dictionary: Repository of data about data (metadata).
41. Gantt Chart: Bar chart for project scheduling.
P a g e 21 | 38
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Practice MCQs
1. Which model is also known as linear- d) Preventive maintenance
sequential model? Answer: b
a) Prototyping 7. Which is NOT a UML diagram?
M Answer: b
2. In DFD, a process is represented by:
d) Use case diagram
Answer: b
K a) Rectangle
b) Circle
8. Process of removing partial
dependency is part of:
c) Rounded rectangle a) 1NF
d) Diamond b) 2NF
P Answer: c c) 3NF
3. Which feasibility deals with "Can the d) BCNF
R system be built with available Answer: b
technology?" 9. In PERT, the most likely time is
E a) Economic weight multiplied by:
b) Technical a) 1
P c) Operational b) 4
d) Legal c) 6
A Answer: b d) 2
Answer: b (Formula: Expected time =
R
4. A many-to-many relationship in ERD
is represented as: (O+4M+P)/6)
A a) 1:1
b) 1:M
10. Which is a characteristic of good
system design?
T c) M:1
d) M:N
a) High coupling
b) Low cohesion
I Answer: d
5. Which testing is conducted by
c) High cohesion
d) Complex interfaces
O developers?
a) Alpha 11.
Answer: c
Which architectural style has all
N b) Beta
c) Acceptance
components tightly integrated?
a) Microservices
S d) Regression b) Client-Server
Answer: a c) Monolithic
6. Modifying system to work in a new d) SOA
environment is: Answer: c
a) Corrective maintenance 12. In structured design, the ideal
b) Adaptive maintenance coupling is:
c) Perfective maintenance a) Content coupling
b) Common coupling
P a g e 31 | 38
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Chapter 23
A 14.
15.
Weights in a neural network represent the importance of connections between neurons.
Biases are threshold adjusters in neural networks that help the model fit the data better.
16. Activation Functions in neural networks determine whether a neuron should be activated.
R 17. Loss Functions measure the difference between the predicted output and the actual target.
18. Training a neural network involves Feedforward Propagation and Backpropagation to minimize error.
A 19. Deep Learning excels at autonomously extracting complex patterns from vast amounts of
unstructured data like images and text.
T 20.
21.
The hierarchical relationship is: AI ⊃ ML ⊃ Neural Networks ⊃ Deep Learning.
Natural Language Processing (NLP) enables computers to understand, interpret, and generate human
I 22.
language.
NLP applications include language translation, spam filtering, sentiment analysis, chatbots, and voice
O 23.
assistants.
Speech Recognition converts spoken words into text or commands (e.g., dictation software, Siri).
24. Voice Recognition is a biometric technology that identifies a person based on unique vocal
N characteristics for security.
25. Computer Vision enables computers to derive meaningful information from digital images and
S 26.
videos.
Applications of Computer Vision include facial recognition, security surveillance, self-driving cars,
and medical image analysis.
27. Expert Systems are interactive AI programs that mimic human expert reasoning to solve complex
problems in a specific domain.
28. Expert Systems use a knowledge base and are applied in medical diagnosis, loan analysis, and
cybersecurity.
P a g e 7 | 17
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
C) Interdisciplinary nature 7. What is the key difference between
D) Prominent impact speech recognition and voice recognition?
Answer: B) Slow and steady growth A) Speech recognition identifies a person;
2. Who coined the term "Artificial voice recognition converts speech to text.
Intelligence"? B) Speech recognition converts speech to text;
P
C) Computer Vision A) Augmented Reality
D) Expert Systems B) Virtual Reality
Answer: B) Machine Learning C) Holographic Imaging
R 4. In machine learning, which type involves D) 3D Printing
algorithms learning from labeled datasets? Answer: B) Virtual Reality
E A) Unsupervised Learning
B) Reinforcement Learning
9. What does AR stand for, and what does it
do?
P C) Supervised Learning
D) Deep Learning
A) Augmented Reality; overlays digital
content onto the real world
A Answer: C) Supervised Learning
5. What is the hierarchical relationship
B) Artificial Reality; creates a completely
virtual world
between AI, ML, Neural Networks, and
R
C) Advanced Rendering; enhances image
Deep Learning? quality
A) AI ⊃ Neural Networks ⊃ ML ⊃ Deep D) Audio Recognition; identifies sounds
A Learning Answer: A) Augmented Reality; overlays
B) AI ⊃ ML ⊃ Neural Networks ⊃ Deep digital content onto the real world
T Learning
C) ML ⊃ AI ⊃ Deep Learning ⊃ Neural
10. Which technology creates a true three-
dimensional, free-standing image viewable
I Networks
D) Deep Learning ⊃ Neural Networks ⊃ ML
without special glasses?
A) 3D Imaging
O ⊃ AI
Answer: B) AI ⊃ ML ⊃ Neural Networks ⊃
B) Holographic Imaging
C) Virtual Reality
D) Augmented Reality
N Deep Learning
6. Which AI subfield enables computers to Answer: B) Holographic Imaging
understand, interpret, and generate human 11. What is another name for 3D printing?
S language? A) Subtractive Manufacturing
B) Additive Manufacturing
A) Computer Vision
B) Robotics C) Injection Molding
C) Natural Language Processing D) CNC Machining
D) Speech Recognition Answer: B) Additive Manufacturing
Answer: C) Natural Language Processing 12. Blockchain is best described as:
A) A type of computer virus
P a g e 12 | 17
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Chapter 24
R Types of Software
1. System Software: The essential set of programs that acts as the primary interface between hardware
and the user. Its purpose is to simplify hardware use, control operations, and optimize performance.
E o Examples: Operating Systems (OS), Device Drivers, Utility Programs, Language Translators.
2. Application Software: Programs written to carry out specific tasks for the user.
P o Examples: Word Processors (Microsoft Word), Spreadsheets (Excel), Presentation Software
(PowerPoint), Web Browsers (Chrome), Email Clients (Gmail), Image Editors (Paint).
A System Software Deep Dive
R The Operating System (OS)
The OS is the most critical system software that controls and manages all computer operations. A
A computer cannot function without it.
T •
Main Functions:
Booting: Loading itself into main memory upon startup.
I •
•
Security Management: Managing user accounts and access.
Application Management: Enabling installation and execution of application programs.
• Memory Management: Organizing memory and processing time between users and programs.
O • File Management: Enabling users to save, load, delete, rename, print, and copy files.
• Device Management: Controlling peripherals (disk drives, printers).
N •
•
User Interface: Providing a bridge between the user and the computer's hardware/software.
Common OS Examples: Microsoft Windows (10, 11), macOS, Linux, Android, iOS.
S Other Essential System Software
• Device Drivers: Specialized programs that enable hardware components (printers, sound cards) to
communicate with the OS.
• Utility Programs: Applications that perform management and maintenance tasks (e.g., Antivirus
software, disk cleanup, backup utilities, file management tools).
• Language Translators: Software that converts human-readable programming code (source code)
into machine-understandable code. Includes Assemblers, Compilers, and Interpreters.
P a g e 1 | 23
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Common Cybercrime Techniques & Prevention
Technique Description Preventive Measures
Inspect sender's address. Don't
Phishing / Email Fake emails from trusted
R Online Transaction
Fraud
Illegal transfer using stolen
bank/credit card details.
Never share PIN, OTP, CVV.
Avoid public Wi-Fi for
A transactions. Review statements.
P a g e 8 | 23
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
One Liners: Digital Citizenship, Ethics and Literacy
1. The digital landscape is the cornerstone of modern society, transforming communication, learning,
work, and entertainment.
2. A computer consists of hardware (physical components) and software (instructions, data, and
A 14.
original item.
Essential file operations include Create, Rename, Cut/Copy/Paste, Delete & Restore, and Drag and
Drop.
R 15. Deleted files are sent to the Recycle Bin, from which they can be restored.
16. A word processor is an application used to create, edit, format, save, and print text-based
A 17.
documents.
Key word processor interface elements include the Quick Access Toolbar, Title Bar, Ribbon, and
T 18.
Document Workspace.
Character formatting in a word processor includes changing Font Style, Size, Color, and applying
I 19.
Bold, Italic, Underline, and Text Alignment.
Page Layout adjustments involve margins, orientation (Portrait/Landscape), and size.
O 20.
21.
Lists can be bulleted (unordered) or numbered (sequential).
Headers and Footers are areas at the top and bottom of every page for titles, page numbers, and
dates.
N 22. Spell & Grammar Check (F7) and Thesaurus are tools for error checking and finding synonyms.
23. Save (Ctrl+S) updates an existing file; Save As (F12) saves a new copy with a different
S 24.
name/location/format.
A multimedia presentation combines text, images, video, and audio (e.g., PowerPoint).
25. Slides can be added with various layouts; objects like text boxes, pictures, videos, audio, and
shapes can be inserted.
26. Speaker Notes are private notes for the presenter, accessible via the Notes pane.
27. Press F5 to start a slideshow; Slide Timings can be set for automatic advancement.
28. Email is a method of exchanging digital messages across computer networks.
P a g e 14 | 23
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Practice MCQs
1. What are the two main components of 7. In a word processor, which tab is used
a computer system? to adjust page margins and orientation?
A) CPU and RAM A) Home
O A) Downloads folder
B) Recycle Bin
events
B) A documentary film about World War II
C) Temp folder C) A soldier's original diary from World
N D) Desktop War II
Answer: B) Recycle Bin D) An encyclopedia entry
S 6. Which keyboard shortcut is used to
copy selected text or files?
Answer: C) A soldier's original diary
from World War II
A) Ctrl+X 12. What does the 'A' in the CRAAP test
B) Ctrl+C for evaluating sources stand for?
C) Ctrl+V A) Authenticity
D) Ctrl+A B) Authority
Answer: B) Ctrl+C C) Accuracy
P a g e 20 | 23
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Chapter 25
P
involves identifying a market need, taking calculated risks under conditions of uncertainty, and making
strategic decisions to achieve business objectives and create value.
A • Innovation and Progress: Drives groundbreaking ideas that transform lifestyles and industries (e.g.,
smartphones, digital platforms).
Job Creation: Generates employment opportunities directly and indirectly.
T
•
• Competition and Improvement: Introduces fresh ideas and competition into the market, leading to
better products, services, and prices for consumers.
I • Social and Environmental Solutions: Through social entrepreneurship, it addresses pressing societal
and environmental challenges.
O Characteristics of a Successful Entrepreneur
N •
Successful entrepreneurs typically exhibit a composite set of the following attributes and skills:
Innovation & Creativity: The ability to create something new or significantly improve existing
solutions through creative thinking.
S • Calculated Risk-Taking: A willingness to undertake financial and personal risks, with an
understanding that failure is possible but great rewards can follow. They are moderate risk-takers, not
gamblers.
• Persistence and Resilience: The determination and self-reliance to overcome inevitable challenges
and setbacks.
• Future Orientation & Opportunity Seeking: Constantly looking ahead for new opportunities and
focused on long-term potential.
P a g e 1 | 28
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Founded on the belief the company can
revolutionize an industry. Heavily reliant on Facebook,
2. Scalable Startup
venture capital, specialized employees, and Instagram, Uber.
targets rapid expansion & big profits.
E 5. Innovative
Driven by the continuous generation of new Steve Jobs (Apple),
ideas and inventions turned into ventures, Bill Gates
P Entrepreneurship
aiming to change lives and industries. (Microsoft).
E
problem, solution, opportunity, team,
Level models, operational plans.
and ask.
P Audience
Investors for due diligence, banks, Potential investors, partners,
I 4.
Weaknesses, Opportunities, Threats), and trends.
Organization & Management: Company structure, biographies of key team members.
5. Products/Services Line: Detailed description of what you sell and its lifecycle.
O 6. Marketing & Sales Strategy: How you will reach customers and your sales process.
7. Funding Request (if applicable): How much capital is needed and how it will be used.
N 8.
o
Financial Projections: The critical section including:
Income Statement (Profit & Loss)
S o
o
Cash Flow Statement
Balance Sheet
o Break-Even Analysis
o Assumptions behind the projections.
R 6. Entrepreneurship acts as a vital catalyst for economic growth by creating new jobs.
7. It drives economic growth by introducing new products and services that stimulate economic
E activity.
P 8. Entrepreneurship is a primary driver of groundbreaking innovation that transforms lifestyles and
A industries.
9. A major impact of entrepreneurship is job creation, generating employment opportunities both
R directly and indirectly.
A 10. By introducing fresh ideas and competition, entrepreneurship leads to better products, services, and
N can follow.
14. Successful entrepreneurs are moderate risk-takers, not gamblers.
S 15. Persistence and resilience are essential attributes for overcoming inevitable challenges and setbacks.
16. Entrepreneurs are future-oriented and constantly seek new opportunities with long-term potential.
17. A deep desire for responsibility and control over the venture's outcomes is a common entrepreneurial
trait.
P a g e 13 | 28
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
215. Potential career paths from entrepreneurship skills include Founder, Product Manager, and Business
Analyst.
216. Other paths include UX/UI Designer, Digital Marketing Manager, and Project Manager.
217. Innovation Consultant and Software Developer are also potential career paths.
M 219. Neuro-Mat identified the problem that nurses cannot monitor every patient continuously, leading to
P 221. Neuro-Mat began with simple, low-fidelity prototypes like buzzer and switch circuits.
R 222. They iterated towards complex systems integrating pressure sensors and microcontrollers.
223. Their market validation Smoke Test showed double the preference over alternatives like baby
E monitors.
P 224. Key learning from feedback was that customers strongly preferred an outright purchase model over
A rental.
225. Customers also valued cash-on-delivery payment options.
R Practice MCQs
A 1. What is the core definition of an
entrepreneur?
d) German
Answer: c) French
T a) An employee who follows company
procedures
3. Which of the following is NOT a primary
impact of entrepreneurship on an
b) An individual who organizes, manages, economy?
I and assumes the financial risks of a new a) Job Creation
business venture b) Economic Stagnation
O c) A government official who regulates
markets
c) Innovation and Progress
d) Increased Competition
N d) A consumer who buys innovative products
Answer: b) An individual who organizes,
Answer: b) Economic Stagnation
4. A successful entrepreneur who takes
S manages, and assumes the financial risks
of a new business venture
financial risks with an understanding of
potential failure, but not recklessly, is best
2. The term "entrepreneur" originates from described as a:
which language? a) Gambler
a) Latin b) Calculated risk-taker
b) Greek c) Avoider of all risk
c) French d) Follower of trends
Answer: b) Calculated risk-taker
P a g e 23 | 28
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Chapter 26
M
• Ctrl + V → Paste copied/cut item → Inserts clipboard content.
• Ctrl + Z → Undo last action → Reverses previous operation.
• Ctrl + Y / Ctrl + Shift + Z → Redo action → Reapplies undone action.
K • Ctrl + A → Select all items → Highlights all content in a window.
• Ctrl + S → Save current document → Saves file in active application.
• Ctrl + F → Open find/search box → Searches for text on a page.
• Ctrl + P → Print current page/document → Opens print dialog.
P •
•
Ctrl + N → Open new window/document → Creates new instance.
Ctrl + W → Close current window/tab → Shuts active tab/window.
R •
•
Ctrl + T → Open new browser tab → Creates tab in browsers.
Ctrl + Shift + T → Reopen closed tab → Restores recently closed tab.
Alt + Tab → Switch between open apps → Toggles running applications.
E
•
• Alt + F4 → Close active application → Quits current program.
• Windows Key + D → Show/hide desktop → Minimizes all windows.
P •
•
Windows Key + E → Open File Explorer → Launches file manager.
Windows Key + L → Lock computer → Locks screen quickly.
A •
•
Windows Key + R → Open Run dialog → Executes commands.
Windows Key + V → Open clipboard history → Shows copied items.
R •
•
Windows Key + . (period) → Open emoji panel → Inserts emojis.
Windows Key + Shift + S → Open Snipping Tool → Takes screenshot.
A •
•
Ctrl + Shift + Esc → Open Task Manager → Directly opens task manager.
F2 → Rename selected item → Renames file/folder.
F5 → Refresh active window → Reloads page/file explorer.
T
•
• Alt + Enter → Open properties → Displays selected item's properties.
I •
macOS
Cmd + C → Copy selected item → Equivalent to Ctrl+C.
O •
•
Cmd + X → Cut selected item → Cuts selected content.
Cmd + V → Paste copied/cut item → Pastes clipboard content.
N •
•
Cmd + Z → Undo last action → Reverses last change.
Cmd + Shift + Z → Redo action → Reapplies undone change.
Cmd + A → Select all items → Selects all content.
S
•
• Cmd + S → Save current document → Saves active file.
• Cmd + F → Find items in document → Opens find bar.
• Cmd + P → Print document → Opens print dialog.
• Cmd + N → Open new window/document → New window.
• Cmd + W → Close current window → Closes active window.
• Cmd + Q → Quit application → Exits program completely.
• Cmd + T → Open new browser tab → New tab in browser.
P a g e 1 | 18
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
• Cmd + Shift + T → Reopen closed tab → Restores closed tab.
• Cmd + Tab → Switch between applications → App switcher.
• Cmd + Space → Open Spotlight search → System-wide search.
• Cmd + Shift + 4 → Take screenshot (area) → Screenshot selection.
• Cmd + Shift + 3 → Take screenshot (full screen) → Captures entire screen.
P •
•
Alt + F2 → Run command dialog → Opens run command box.
Super Key (Windows Key) → Open activities overview → Shows activities.
Ctrl + Alt + L → Lock screen → Locks the session.
A
•
• Ctrl + Alt + Delete → Open logout dialog → Shows logout options.
• Ctrl + Alt + Arrow Keys → Switch workspaces → Moves between workspaces.
R •
•
Ctrl + Shift + N → New folder in file manager → Creates folder.
Ctrl + H → Show hidden files → Toggles hidden files visibility.
A • Ctrl + Alt + F1/F7 → Switch to terminal/GUI → Toggles TTY and GUI.
A •
•
Algorithm: Step-by-step procedure for solving a problem or performing a computation.
Data Structure: Particular way of organizing data for efficient access and modification.
Array: Collection of items stored at contiguous memory locations.
R
•
• Linked List: Linear data structure where elements are linked using pointers.
• Stack: LIFO (Last In, First Out) linear data structure.
A •
•
Queue: FIFO (First In, First Out) linear data structure.
Tree: Hierarchical data structure with a root value and subtrees of children.
T •
•
Graph: Non-linear data structure of nodes (vertices) connected by edges.
Hash Table: Data structure that maps keys to values using a hash function.
I •
•
Time Complexity: Amount of time an algorithm takes relative to input size.
Space Complexity: Amount of memory an algorithm uses relative to input size.
O •
•
Big O Notation: Mathematical notation describing algorithm complexity's upper bound.
Compiler: Program that translates source code from a high-level language to machine code.
Interpreter: Program that directly executes instructions written in a programming language.
N
•
• Syntax: Set of rules defining the combinations of symbols in a programming language.
• Semantics: Meaning of the syntactically valid statements in a programming language.
S •
•
Object-Oriented Programming (OOP): Paradigm based on objects containing data and methods.
Class: Blueprint for creating objects in OOP.
• Object: Instance of a class.
• Inheritance: Mechanism where a class derives properties from another class.
• Polymorphism: Ability of an object to take on many forms, often through method
overriding/overloading.
• Encapsulation: Bundling of data with methods operating on that data, hiding internal state.
P a g e 7 | 18
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
Past Papers Questions
1. How many rows in MS Excel Sheet? 8. Gmail, Hotmail and Yahoo are:
A) 86340 A) Email Server
P A) Videos
B) Images
processing software?
A) Browser
C) Files B) PowerPoint
A D) None of these C) MS Word
Answer: B) Images D) None of these
R Answer: C) MS Word
5. Which key is used to move the cursor to
end of the line? 12. The first computers were programmed
A A) End
B) Home
using:
A) Assembly language
T C) Shift+ tab
D) None of these
B) Machine language
C) Object code
I Answer: A) End
6. In MS-DOS, DOS stands for:
D) None of these
Answer: B) Machine language
A) Disk Operating System 13. The computer cannot boot if it cannot
O B) Device Operating System load the:
C) Driver Operating System A) Loader
N D) None of these
Answer: A) Disk Operating System
B) Operating system
C) Assembler
S 7. HTML stands for hypertext markup
language is used for creating:
D) None of these
Answer: B) Operating system
A) Web pages 14. BIOS stands for:
B) Web server A) Basic Input Output System
C) Client server B) Binary Input Output System
D) None of these C) Broad Input Output System
Answer: A) Web pages D) None of these
Answer: A) Basic Input Output System
P a g e 1 | 21
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
MK PREPARATIONS
15. LCD stands for: 22. Which button do you click to add up a
A) Light Clear Display series of numbers?
B) Liquid Crystal Display A) Auto sum
C) Light Crystal Display B) Formula button
D) None of these C) Total Button
A D) None of these
Answer: B) CTRL+F9
D) None of these
Answer: A) Computer aided design
19. Videos, documents and files can be shown 26. When you open a new presentation, a
R in: slide with the default layout appears?
A) WhatsApp A) Blank
A B) YouTube
C) Skype
B) Home
C) Title
T D) None of these
Answer: D) None of these
D) None of these
Answer: C) Title
I 20. The extension of a PowerPoint file is:
A) XLS
27. The capacity of a floppy disk is:
A) 1.22 MB
O B) PPT
C) TXT
B) 1.33 MB
C) 1.44 MB
D) All of these D) None of these
N Answer: B) PPT Answer: C) 1.44 MB
21. In MS Word, Header and Footer are 28. Which key is used to insert text in a cell?
S inserted in:
A) Front page
A) Enter
B) Space
B) Last page C) Tab
C) On every page D) None of these
D) None of these Answer: B) Space
Answer: C) On every page 29. What is the smallest width of a column in
Excel?
P a g e 2 | 21
MK PREPARATIONS: Let’s Make It Happen
+92 333 2605045, +92 342 4470091
System software primarily acts as an intermediary between computer hardware and application software, managing resources and providing a stable environment for applications to function . It is usually pre-installed and necessary for the basic operation of the computer, including the operating system and device drivers. Application software, on the other hand, is designed to perform specific user-directed tasks such as word processing or web browsing, which are optional and installed based on user needs .
Converting a decimal number to binary involves dividing the number by 2 repeatedly, recording the remainder at each step, and reading the remainders in reverse order as the binary equivalent. This method is important because all digital computing and processing rely on binary representation. This conversion is integral for programming as it allows easy manipulation of data by digital devices, establishing a common framework for processing and storage .
The Control Unit (CU) in the CPU is responsible for fetching, decoding, and executing instructions from software programs. It directs data transfer and controls the flow of data between the CPU and other components. Essentially, the CU acts as the brain within the CPU, interpreting program instructions and turning them into control signals that manage the operations of the arithmetic logic unit and other system components, ensuring that instructions are processed correctly and efficiently .
Utility software complements system software by offering specialized functions that support system maintenance, optimization, and security. While system software like the OS manages fundamental operations and resource allocation, utility software performs tasks such as virus protection, disk cleanup, and data backup. These utilities ensure the computer runs efficiently, prolongs hardware life, and protects against potential threats. The synergy between system software and utility programs provides a stable and reliable operating environment that enhances overall performance .
The binary system facilitates a computer's processing of data by representing all types of information—such as text, images, and sound—as binary code (0s and 1s). This system is integral because it uses a base of 2, allowing digital computing to operate on simple on-and-off states represented by 1 and 0. Binary is compact and adaptable for processing with electronic components like the CPU and RAM, where data can be easily manipulated as electrical signals. For example, a bit, the smallest unit, holds either a 0 or 1, and bytes group these bits for larger data measurements .
As a resource manager, the OS efficiently allocates hardware components, such as CPU time, memory space, and I/O devices, to various applications and processes. It also ensures that multiple tasks run smoothly by managing conflicts and prioritizing system resources, which optimizes performance and prevents bottlenecks . This role is crucial because it determines a system's ability to handle concurrent processes, maintain stability during multitasking, and recover from errors without affecting other operations. The OS's resource management capabilities directly affect the user experience and overall system efficiency.
The CLI offers powerful and flexible system management capabilities but demands detailed command knowledge and memorization, which makes it less user-friendly for beginners. It allows for direct and efficient control of system operations with a smaller memory footprint and is ideal for automation and scripting . In contrast, a GUI provides a more intuitive interaction with system resources through visual elements, enhancing usability for non-expert users but can be less efficient in handling complex tasks and scripts . The choice between CLI and GUI often affects the speed and efficiency of administrative tasks and user accessibility.
The "Quick Access Toolbar" in a word processor offers a customizable set of frequently used commands such as Save and Undo, providing users quick access without navigating through the main interface. In contrast, the "Ribbon" is a broader interface that organizes available tools and features into tabs, facilitating comprehensive access to functionalities ranging from text formatting to advanced document elements . While the Toolbar enhances efficiency for routine tasks, the Ribbon provides more depth for document management and editing.
HTML provides the foundational structure of web content by defining elements like headings, paragraphs, links, and images . CSS complements HTML by controlling the presentation, layout, and styling, such as colors, fonts, and spacing. This separation of structure and style allows for more flexible and maintainable web design, as the same HTML document can be presented differently through various CSS stylesheets, enhancing user experience and design consistency .
Digital computing has revolutionized communication, learning, work, and entertainment by enabling rapid information exchange, automation, and global connectivity. However, it has also introduced ethical challenges such as privacy concerns, cybersecurity risks, digital divide, and the ethical use of artificial intelligence. These challenges require users and developers to consider ethical frameworks and citizenship practices in a technology-driven world to ensure responsible and safe participation in the digital ecosystem .