WorksheetsUNIT I: Fundamentals of Computers
Total questions: 150
Worksheet time: 1hrs 15mins
Which statement best defines a computer in this unit?
A mechanical tool that prints documents only
An electronic device that manipulates data
A network cable that connects two devices
A portable gadget for entertainment purposes
Which trio describes core data operations of a computer?
Store, retrieve, process
Scan, copy, fax
Transmit, route, switch
Design, debug, deploy
Which classification refers to personal computers?
Workstations
Supercomputers
Mainframes
Microcomputers
Which is NOT listed as a reason to use computers?
Fragility
Reliability
Efficiency
Accuracy
Which group lists basic computer components?
Browser, website, hyperlink
Battery, charger, power strip
Monitor, wallpaper, screensaver
Input devices, CPU, output devices
Which unit contains the Arithmetic and Logic Unit and control?
Input interface board
Central Processing Unit
Main memory module
Auxiliary storage bay
What does computer science primarily study?
Computers and computing theory and applications
Only electrical circuits inside processors
Historical timelines of supercomputers
Only business uses of spreadsheets
Which set lists examples of software from the unit?
CPU, RAM, SSD
Cable, router, switch
Keyboard, mouse, monitor
MS Word, Excel, Chrome
Which description best fits hardware?
Physical components you can touch
Executable code stored in memory
Cloud services for web hosting
Abstract algorithms and data
Which statement defines computation in this unit?
Random trial processes without structure
Only arithmetic performed by handheld calculators
Any calculation following a well-defined model
Graphic design tasks done on computers
What is computational problem solving?
Using algorithms and programs to solve problems
Drawing flowcharts without implementing
Guessing results and checking later
Buying faster hardware to avoid delays
Which two elements are essential to solve a problem computationally?
A fast printer and a scanner
A spreadsheet and a slideshow
A suitable representation and an algorithm
An operating system and antivirus
Which example illustrates limits of computational problem solving discussed here?
Travelling Salesman Problem
Printing a document
Sorting a small array
Adding two integers
Why can a brute-force approach to TSP be impractical?
Distances between cities are always zero
Number of possible routes grows factorially
Computers cannot compare route lengths
Maps cannot be represented digitally
For ten cities in TSP, how many possible routes are there under brute force?
10 possible routes
210 possible routes
102 possible routes
10! possible routes
Which item belongs to hardware rather than software?
Printer device
Operating system
Web browser app
Spreadsheet file
Which misconception about computers is corrected by this unit?
Computers convert raw data into information
Computers are only for entertainment uses
Computers cannot store data reliably
Computers have no role in communication
Which scenario best requires DoK 3 reasoning with these concepts?
Choosing an efficient algorithm for many cities
Recalling the definition of microcomputer
Listing three common output devices
Identifying icons of office software
Which statement best defines a computer algorithm?
An endless loop that tries solutions
Any informal idea for solving tasks
Random instructions executed by hardware
A finite sequence of unambiguous steps
Why are computer algorithms central to computer science?
They provide step-by-step computation
They replace all computer hardware
They guarantee instantaneous results
They remove the need for software
In binary representation, what values can a single digit take?
Only 0 or 1
Any number 0 through 9
Only 1 or 2
Any integer value
What does the base (radix) of a number system indicate?
Speed of arithmetic operations
Count of unique digits used
Power of ten in each column
Largest place value available
Which hardware component is called the brain of the computer?
Main memory module
Central processing unit
Input device panel
Magnetic storage unit
What is the primary difference between main and secondary memory?
Volatility versus persistence
Size versus speed only
User versus kernel control
Analog versus digital signals
What is the value of the binary place labeled 25 in base 2?
64 in decimal value
32 in decimal value
16 in decimal value
8 in decimal value
Which statement about integrated circuits is accurate?
They contain many transistors
They operate without power
They store data magnetically
They are purely mechanical
What does the term bit stand for?
Basic integer type
Binary digit unit
Bitwise instruction
Buffered input tool
How many bits are in one byte?
Four bits total
Sixteen bits total
Ten bits total
Eight bits total
Which unit immediately follows gigabyte in the metric list shown?
Megabyte unit
Terabyte unit
Petabyte unit
Kilobyte unit
Which task is the operating system primarily responsible for?
Providing permanent power
Compiling source programs
Managing hardware resources
Designing algorithms automatically
During the SDLC, which activity belongs to the Analysis phase?
Clearly understand the problem
Package final media files
Represent data in code
Execute programs on hardware
Which action aligns with the Design phase of the SDLC?
Determine required data structures
Purchase peripheral devices
Run acceptance benchmarks
Refactor low-level drivers
Which step characterizes Implementation in the SDLC?
Collect user satisfaction surveys
Estimate long-term maintenance
Authorize procurement budgets
Express algorithms in a language
What is the primary goal of Testing in the SDLC?
Rewrite the project charter
Detect and correct errors found
Increase CPU clock speeds
Compress executable binaries
A light switch analogy for binary digits illustrates which property?
Three-valued logic gates
Two possible states only
Analog voltage ranges
Infinite discrete levels
You must store programs for long-term retention when power is off. Which storage should you select?
Volatile primary main memory
Temporary cache exclusively
CPU internal registers only
Non-volatile secondary memory
Which term best describes Python in terms of program translation and execution model?
Transcompiled to Java source directly
Assembled into platform firmware images
Interpreted with bytecode execution model
Compiled ahead to native machine code
Which pair correctly lists two emphasized characteristics of Python at the outset?
Closed-source and licensed
Statically typed and verbose
Interactive and object-oriented
Low-level and hardware-near
What does it mean that Python is considered beginner’s language?
It forbids advanced libraries entirely
It replaces all code with drag-and-drop
It uses minimal keywords and simple syntax
It only runs example programs from books
Which feature explains why programmers do not usually manage memory manually in Python?
Explicit free calls after object deletion
Compile-time region annotations for objects
Automatic memory management with garbage collection
Mandatory pointer arithmetic for arrays
Which statement best captures Python’s portability claim?
Scripts must be packaged into firmware images
Binaries are tied to one processor family
Source runs unchanged across many platforms
Programs require separate rewrites per device
What aligns with Python being a high-level language?
Developers manage registers directly
Focus on abstract data types and operations
Write kernel drivers first for I/O
Manual stack frame layout for functions
Which idea distinguishes procedure-oriented from object-oriented styles as supported by Python?
Procedures are graphical; objects only command-line
Procedures mandate inheritance; objects forbid encapsulation
Procedures require classes; objects avoid methods entirely
Procedures reuse functions; objects combine data and behavior
Which benefit is most closely tied to Python’s lack of type declarations in typical code?
Guaranteed compile-time overflow checks
Deterministic real-time execution deadlines
Simpler, shorter, more flexible programs
Faster pointer dereferencing in loops
Which statement about dynamic loading of C modules in Python is accurate?
Loading requires a full operating system reboot
Modules must be statically linked at build time
Extensions can be added without stopping programs
Only Java bytecode extensions are supported
Which description fits CPython among Python flavors?
Reference implementation written in C language
Python runtime implemented in Java for JVM
Front-end that outputs only C++ templates
Meta-tracing JIT entirely in RPython
What is Jython primarily designed to do?
Use CUDA cores for automatic array parallelism
Run Python on the Java platform with JVM integration
Compile Python directly to native Windows executables
Translate Python into C header-only libraries
Which outcome follows from Python generating bytecode when compiled or executed?
Bytecode can run on a Python Virtual Machine
Bytecode must be linked into kernel space
Bytecode executes only on one CPU vendor
Bytecode disables dynamic typing features
You must choose a Python flavor to embed within a large Java application while keeping access to Java classes. Which choice best fits?
MicroPython for desktop integration
PyPy for ahead-of-time C compilation
Jython for seamless JVM interoperability
CPython for native POSIX threads
A team needs faster runtime through just-in-time compilation while still running Python semantics. Which flavor is the most plausible option?
IronPython with bytecode to firmware
Jython using only static compilation
CPython without any JIT support
PyPy with tracing JIT optimizations
Which statement best describes the role of the Python Virtual Machine (PVM)?
It compiles source directly to native binaries
It packages dependencies for distribution only
It converts bytecode to machine code for execution
It manages GUI rendering for Python windows
Which Python flavor is tightly integrated with the .NET Framework?
PyPy with tracing JIT compiler
IronPython open-source implementation
Stockless Python stackless engine
.NETPy proprietary bridge layer
Ruby Python primarily serves as what between ecosystems?
A packaging tool for Ruby gems
A transpiler from Ruby to C code
A bridge between Ruby and Python interpreters
A bytecode optimizer for Ruby VMs
Anaconda Python is mainly used to simplify which tasks?
Mobile app compilation for Android
Scientific package management and deployment
Kernel development and driver signing
Low-level networking and sockets tuning
In the typical Python execution pipeline, what is the correct order?
Source code to IR to JIT to firmware
Source code to assembler to CPU
Source code to bytecode to PVM to machine code
Source code to machine code to linker
Static memory allocation in Python context is associated with which storage structure?
Register file inside the CPU
Global area for shared libraries
Heap region for dynamic objects
Stack structure storing static memory
Dynamic memory allocation primarily uses which area and when?
ROM while loading modules
Registers during interpretation
Heap at runtime when needed
Stack at compile time only
What triggers Python’s garbage collector to reclaim an object under reference counting?
When module import finishes
When CPU usage becomes high
When object age exceeds threshold
When reference count drops to zero
Which action typically increases an object’s reference count?
Assigning a new name to the object
Reassigning the variable elsewhere
Deleting the object explicitly
Letting the reference go out of scope
Which action decreases an object’s reference count?
Creating a shallow copy list
Adding it to a tuple container
Incrementing an integer attribute
Reassigning the variable to another object
A program creates x = [0]*2 and later del x. Under reference counting, what happens to the list object?
It becomes compiled to native code
It moves from stack to registers
Its reference count drops and may be freed
Its references increase and persist
Why is Stackless (Stockless) Python notable in the text?
It uses C stack but clears between calls
It eliminates the C stack between function calls
It targets embedded microcontrollers only
It replaces PVM with a JIT compiler
Who is credited with conceptualizing the Python programming language in the late 1980s?
James Gosling
Rasmus Lerdorf
Bjarne Stroustrup
Guido Van Rossum
Where was the first public release of Python (version 0.9.0) published in February 1991?
MIT in Cambridge
CWI in Amsterdam
Bell Labs in Murray Hill
Stanford in Palo Alto
Python’s name was chosen because its creator was a fan of which British comedy group’s show?
The Comic Strip Presents
Monty Python’s Flying Circus
Little Britain
The Two Ronnies
Which language at CWI influenced Python’s design as a general‑purpose language?
ABC programming language
AWK scripting language
PASCAL systems language
BASIC beginner’s language
Arrange these version milestones in chronological order from earliest to latest: Python 1.0, Python 2.0, Python 3.0.
3.0, 2.0, 1.0
1.0, 3.0, 2.0
1.0, 2.0, 3.0
2.0, 1.0, 3.0
Which company in the visual list is best known as a major search engine that uses Python in multiple services?
Google, a search engine company
Netflix, a streaming provider
Dropbox, a storage platform
Spotify, a music service
Select the platform from the image that primarily offers music streaming and uses Python.
Spotify, a music platform
Dropbox, a file service
YouTube, a video site
Quora, a Q&A site
Which pair both appear in the image as companies using Python and are video-related platforms?
YouTube and Netflix
Google and BitTorrent
Quora and Dropbox
Instagram and Spotify
A startup building peer-to-peer file distribution tools wants examples of Python adopters with similar models. Which logo from the image best fits this need?
Facebook for social networking
BitTorrent for peer-to-peer
Quora for knowledge sharing
Instagram for photo sharing
If a company plans to integrate cloud file synchronization features and seeks a Python-using role model from the image, which should they study first?
Quora for Q&A
Dropbox for file sync
Spotify for playlists
Instagram for stories
Which area is a common real‑world application of Python?
Astrology and horoscopes
Mechanical gear shaping
Analog circuit design
Web and internet development
What does IDE stand for in the context of Python development?
Integrated Development Environment
Interactive Design Emulator
Internal Debug Executor
Independent Deployment Engine
Which component is typically included in an IDE to help find program errors?
A firmware flasher
A packet sniffer
A hardware oscilloscope
A program debugger
Python is most commonly executed using which mechanism?
A linker-loader
A microkernel
A bytecode burner
An interpreter
In IDLE, what is the interactive window that lets you execute statements immediately called?
The command linker
The runtime cache
The static console
The Python shell
Which option best describes the Python Standard Library?
A set of paid plug‑ins
A repository of compiled binaries
A third‑party app marketplace
A collection of built‑in modules
You need to prototype a small GUI tool and then debug it step by step. Which IDLE features directly support this workflow?
Daemon and cron tools
Editor and debugger tools
Hypervisor and snapshot tools
Assembler and linker tools
A student wants functionality beyond Python’s core without installing packages. What should they explore first?
Modules in the Standard Library
Kernel device drivers
Cloud orchestration stacks
Custom machine code inserts
Which category in Python literals includes integer, float, and complex values?
Special literals category in Python
Boolean literals category in Python
Numeric literals category in Python
String literals category in Python
Which option lists only collection literal types as shown in the diagram?
True, False, None, Dictionary
List, Tuple, Set, Dictionary
String, Boolean, Integer, List
Integer, Float, Complex, Tuple
What is the best example of a Boolean literal in Python?
1 used as truthy value
True without quotes
None used in a condition
'True' enclosed in quotes
A value like 3+4j belongs to which literal subtype according to the categorization?
Special literal subtype
Complex literal subtype
Integer literal subtype
Float literal subtype
Which statement correctly contrasts string literals with collection literals based on the diagrammed categories?
Strings store multiple keyed pairs, collections do not
Strings represent text values, collections group multiple items
Strings are numeric values, collections are textual values
Strings are Booleans, collections are numbers
You need an unordered collection of unique items as a literal. Which collection type fits this requirement?
Set literal with unique membership
Tuple literal that is mutable sequence
List literal with duplicates allowed
Dictionary literal storing only values
Consider initializing configuration flags. Which literal choice makes the intent most explicit?
Use numeric 1 and 0 for flags
Use string 'yes' and 'no' values
Use Boolean True and False literals
Use None for enabled and disabled
Which is a valid Python string literal?
AMJ College enclosed in brackets
AMJ-College using hyphen only
AMJ College without any quotes
"AMJ College" enclosed in quotes
Which statement best describes a single-line string in Python?
Text without quotation marks
Text stored as numeric code
Text spanning many lines
Text terminated within one line
Which is a correct way to create a multi-line string?
Using triple quotation marks
Placing spaces between words
Ending each line with semicolons
Using single quotes repeatedly
Which numeric literal has no fractional part?
Scientific like 1e3
Float like 123.45
Integer like 100
Complex like 67+89j
Which option represents a float literal?
12345 without decimal
123.45 with decimal
67+89j as complex
True as boolean
Which Python literal represents the absence of a value?
None special literal
Zero numeric value
Empty string literal
False boolean value
What values can a Boolean literal take in Python?
On or Off words
Yes or No strings
1 to 0 range
True or False only
Consider the code: a = 10; a = a + 2; print(a). What will be displayed?
a printed as text
Error due to types
12 after reassignment
10 without change
Which name is a valid Python variable identifier?
2price starting with digit
price-2 using hyphen
price2 starting with letter
price 2 with space
Which assignment correctly binds a string value to a variable?
name == John
name = "John"
"name" = John
name : John
Which statement about constants is accurate in Python practice?
A constant must be an integer only
A constant’s value should not change
A constant must be declared with const
A constant cannot be assigned initially
Which literal type includes a real and an imaginary part?
Float numbers like 123.45
Complex numbers like 67+89j
Boolean values like True
Integer numbers like 100
Which is a valid Python identifier under naming rules?
value%tax
_totalSum
first-name
2nd_value
class
Which statement about Python identifiers is correct?
They may start with underscore
They may duplicate any keyword
They may contain spaces inside
They may use @ or # symbols
They may start with a digit
Identify the set containing only allowed identifier characters (after first position).
digits, hyphen, spaces, percent
lowercase, at-sign, caret, slash
lowercase, uppercase, digits, underscore
uppercase, spaces, hash, star
underscore, colon, comma, semicolon
Which option shows case sensitivity of identifiers?
Python ignores letter casing always
SUM and sum must match
total and total are different
myVar and MyVar are different
Name and name are identical
Choose the invalid identifier and the reason.
for, reserved keyword
value2, starts with letter
rate%, ends with percent
_index, uses underscore
DataSet, mixed case allowed
How many keywords exist in Python 3.7 as listed in the table?
28 keywords total
33 keywords total
30 keywords total
25 keywords total
35 keywords total
Select the true statement about Python keywords.
They can be variable names
They change at runtime
They are case sensitive
They are valid identifiers
They require module import
Which group contains only Python keywords?
True, none, class
if, else, while
main, then, begin
int, str, float
print, input, pass
What does the input function primarily do in Python?
Displays text without reading
Reads user data from keyboard
Converts types automatically
Validates numeric ranges
Terminates program execution
Given code: name = input('What is your name?: '), what is 'What is your name?: ' called?
A multiline comment
A prompt string
A keyword literal
A docstring for module
A format specifier
Which statement best describes the print function?
It evaluates input expressions
It handles file I/O by default
It declares variables globally
It displays information on screen
It compiles Python source
You must create a variable for number of attempts. Choose the best identifier.
num attempts
attempts_count
3attempts
attempts%count
return
Which print call correctly outputs the line with double quotes around Welcome to Python Programming?
print('"Welcome to Python Programming"')
print("\"Welcome to Python Programming\"")
print("Welcome to Python Programming")
print('Welcome to Python Programming')
Given num1 = int(input()), num2 = int(input()), which statement correctly prints the product with a label?
print('Multiplication is = ' + str(num1), str(num2))
print('Multiplication is:' + num1 * num2)
print('Multiplication is' + num1, num2)
print('Multiplication is', num1 * num2)
What will be printed by print('My', 'Name', 'Is', ' I BCA D ', sep='**')?
My**Name**Is** I BCA D
My Name Is I BCA D
My**Name Is** I BCA D
My*Name*Is* I BCA D
Which formatting prints the float value 458.541315 rounded to two decimal places using percent-formatting?
print('{:.02}'.format(458.541315))
print('%.2f' % 458.541315)
print(round(458.541315, '2'))
print(f'%2f' % 458.541315)
Which code correctly accepts three space-separated names in one input and prints them on separate lines?
a,b,c = map(input().split()); print(a,b,c)
a,b,c = input(); print(a); print(b); print(c)
a,b,c = input().split(); print(a); print(b); print(c)
names = input().split(); print(names)
For BMI calculation with weight in kilograms and height in meters, which expression is correct?
bmi = weight*height*height
bmi = weight/(height*height)
bmi = weight/height
bmi = (height/weight)*height
Which statement best defines an operator in Python?
A symbol that performs an operation on operands
A procedure that converts strings to integers
A stored value assigned to a variable name
A container that holds multiple values in order
Which operator performs exponentiation in Python?
%% double percent for power
caretoperatorforpower
** double asterisk for power
pow as infix arithmetic
What is the result of 9 // 2 in Python?
4 with floor removal
4.0 as float quotient
5 after rounding up
4 remainder two kept
Which arithmetic operator returns the remainder of division?
// floor division operator
/ true division operator
% modulus operator
* multiplication operator
Given a = 20 and b = 5, which expression evaluates to 4?
b ** a gives power
a / b gives quotient
a % b gives remainder
a // b gives quotient
Which statement about comparison operators is correct?
!= checks inequality
>= means strictly greater than
<= means strictly less than
== assigns a value
Evaluate the relational expression: 7 < 10 and 7 > 20
False because both are false
False because one is false
True because both are true
True because one is true
Which operator assigns a value to a variable?
== equality comparator
= assignment operator
:= walrus operator
=> arrow assignment
Choose the expression that evaluates to True:
7 == 10 equality check
7 >= 10 comparison test
7 != 10 inequality check
7 > 10 comparison test
What is the effect of the not operator in Python?
It compares two values
It reverses a condition
It performs bitwise negation
It doubles boolean values
If x = 3 and y = 8, which expression is True?
not x < y and x < y
x < y or x == y
x > y and x == y
x >= y and x < y
Which option best describes arithmetic operators in Python?
They compare two operands
They assign values to variables
They perform mathematical operations
They test membership in containers
Consider: a = 15, b = 4. What is a % b?
3 because remainder three
4 because divisor returned
3.0 because float output
-1 due to truncation
Which expression demonstrates floor division producing a float?
9 % 2 gives remainder
9 / 2 gives float
9.0 // 2.0 gives float
9 // 2 gives integer
Select the correct pairing of operator and meaning.
< means less than or equal to
>= means greater or equal to
== means assignment operator
!= means equal to operator
For booleans p and q, which expression is True only when both are True?
p or q logical disjunction
p and q logical conjunction
not p unary inversion
p == q equality relation
Which bitwise operator performs a binary OR between two integers?
| operator between operands
& operator between operands
^ operator between operands
~ operator on operand
What is the result of 5 & 3 using bitwise AND on integers?
-6 after complementing
1 after binary comparison
7 after combining bits
6 after toggling bits
For integers, what does the left shift operator << do to the left operand?
Combines bits using exclusive OR
Flips every bit of the value
Moves bits left by given count
Moves bits right by given count
Evaluate 100 >> 2 for integer right shift with zero fill on positive numbers.
25 after shifting two places
400 after shifting two places
50 after shifting two places
200 after shifting two places
Which expression checks sequence membership and returns True when an element exists in a list?
3 is [1,2,3,4]
3 == [1,2,3,4]
3 not in [1,2,3,4]
3 in [1,2,3,4]
Choose the statement that correctly uses the not in operator with a tuple.
'x' not in ('a','b')
'x' in ('a','b')
'x' is ('a','b')
'x' == ('a','b')
Which operator compares whether two variables refer to the same object in memory?
in membership operator
is identity operator
== equality operator
^ bitwise operator
Given a = [1,2]; b = a; c = [1,2]. Which expression is True?
a == b evaluates False
a is b evaluates True
a in c evaluates True
a is c evaluates True
Which statement best defines an expression in Python?
A compiled unit that optimizes runtime speed
A named block that groups reusable procedures
A sequence of statements that changes program state
A combination of symbols that evaluates to a value
In the arithmetic expression z = a + b - c * d / e, which operation is applied first under standard precedence?
Division of the result by e first
Subtraction of c from the sum a+b
Addition of a and b before others
Multiplication of c and d before division
What is a sub-expression in the context of arithmetic expressions?
Any expression that is part of a larger expression
Any expression evaluated after assignment
Any expression that contains only literals
Any expression that returns a Boolean
Given x = (y + z) * n, why are parentheses used around y + z?
To allocate memory for the variables
To reduce floating-point rounding errors
To override precedence and force addition first
To cast the sum to integer type
Consider Python's operator precedence and evaluate the numeric result: 3 + 4 * 2 - 8 / 4.
3.0 because addition executes before all
11.0 because operators evaluate left to right
2.0 since subtraction has highest precedence
9.0 after applying multiplication and division first
Which operators have the highest precedence when evaluating a Python expression?
Parentheses grouping with ()
Exponentiation with **
Unary plus and minus
Multiplication and division
What is the associativity of the exponentiation operator ** in Python?
Right to left evaluation
Left to right evaluation
No defined associativity
Alternating by nesting
In the expression 2 ** 3 ** 2, how is it evaluated under Python’s rules?
2 ** 3 * 2
(2 ** 3) * 2
(2 ** 3) ** 2
2 ** (3 ** 2)
Which group of operators shares left-to-right associativity according to the table?
Parentheses grouping
*, /, //, %
Assignment operators
Lambda expressions
