WorksheetsComputer Science Quiz
Total questions: 85
Worksheet time: 43mins
The parser which is used to produce a syntax tree is known as:
Lexical Analyzer
Syntax Analyzer
Semantic Analyzer
Intermediate Code Generator
Which layer of the OSI model is responsible for data encryption?
Application Layer
Presentation Layer
Session Layer
Transport Layer
What is the purpose of the JOIN operation in SQL?
To combine columns from multiple tables
To delete rows from a table
To update rows in a table
To insert rows into a table
Which of the following is not a type of kernel?
Monolithic kernel
Microkernel
Exokernel
Nanokernel
Which layer of the OSI model is responsible for establishing, managing, and terminating connections between applications?
Physical Layer
Data Link Layer
Network Layer
Transport Layer
Which of the following is not a characteristic of a greedy algorithm?
Optimal substructure
Overlapping subproblems
Local optimal choice
Feasible solutions
Which of the following is not a cryptographic algorithm?
AES
RSA
SHA-256
FTP
In machine learning, overfitting occurs when:
The model performs well on the training data but poorly on new, unseen data.
The model performs well on new, unseen data but poorly on the training data.
The model has a high bias but low variance.
The model has low bias and low variance.
The traveling salesman problem (TSP) is an example of:
P problem
NP problem
NP-complete problem
NP-hard problem
The language accepted by a Turing machine is:
Context-Free Language
Context-Sensitive Language
Regular Language
Recursively Enumerable Language
Which of the following data structures is best suited for implementing a priority queue?
Stack
Queue
Linked List
Heap
Which of the following automata has the simplest computational power?
Turing Machine
Pushdown Automaton
Finite Automaton
Linear Bounded Automaton
What is the time complexity of the merge sort algorithm in the worst case?
O(n)
O(n log n)
O(n^2)
O(log n)
Which of the following is not a type of CPU architecture?
Harvard
Von Neumann
RISC
FIFO
In graph theory, a graph with no cycles is called a:
Tree
Complete Graph
Bipartite Graph
Multigraph
The pumping lemma is used to prove that:
A language is regular
A language is context-free
A language is not regular
A language is not context-free
In which phase of the SDLC is the software design created?
Requirement Analysis
Design
Implementation
Maintenance
In software engineering, which model is also known as the "Waterfall Model"?
Agile Model
Incremental Model
Spiral Model
Linear Sequential Model
Which memory allocation scheme suffers from external fragmentation?
Paging
Segmentation
Contiguous allocation
None of the above
Which problem is undecidable?
Whether a context-free grammar generates any strings
Whether a context-free grammar generates an infinite language
Whether a Turing machine halts on all inputs
Whether a finite automaton accepts a given string
Which testing is performed to ensure that new code changes do not adversely affect the existing functionality?
Unit Testing
Integration Testing
Regression Testing
System Testing
Which sorting algorithm is stable?
Quick Sort
Heap Sort
Merge Sort
Selection Sort
Which protocol is used to retrieve email from a mail server?
HTTP
FTP
SMTP
IMAP
Which of the following operations is not performed in a stack?
Push
Pop
Enqueue
Peek
What is the main function of the command interpreter?
To execute binary files
To handle system calls
To manage hardware devices
To provide a user interface
A multiplexer is a combinational circuit that:
Generates multiple outputs
Selects one input from multiple inputs
Stores data
Encodes data
In Boolean algebra, the expression A + 0 is equivalent to:
A
0
1
A'
In a multi-threaded environment, which of the following is a synchronization tool?
Semaphore
Compiler
Loader
Linker
In a relational database, what does ACID stand for?
Atomicity, Consistency, Isolation, Durability
Availability, Consistency, Isolation, Durability
Atomicity, Consistency, Integrity, Durability
Availability, Consistency, Integrity, Durability
What does UML stand for in software engineering?
Universal Markup Language
Unified Modeling Language
Unstructured Modeling Language
Universal Modeling Language
What is the main function of the Domain Name System (DNS)?
To map IP addresses to domain names
To provide secure data transmission
To manage network congestion
To enable error detection and correction
In TCP/IP model, which layer is responsible for routing packets?
Application Layer
Transport Layer
Internet Layer
Network Access Layer
Which algorithm design technique is used in the Quick Sort algorithm?
Dynamic Programming
Greedy Algorithm
Divide and Conquer
Backtracking
What is the time complexity of the binary search algorithm?
O(n)
O(log n)
O(n log n)
O(n^2)
The term "ping" is associated with:
HTTP
ICMP
SMTP
FTP
Which SQL command is used to remove a table from a database?
DELETE
DROP
TRUNCATE
REMOVE
What is the primary goal of software engineering?
To increase hardware efficiency
To reduce the cost of software
To produce high-quality software
To develop software quickly
What data structure is used in a Breadth-First Search (BFS) algorithm?
Stack
Queue
Linked List
Tree
Which of the following is not a software development life cycle (SDLC) model?
Waterfall Model
V-Model
Agile Model
CPU Model
Which of the following is a non-preemptive scheduling algorithm?
Round Robin
Shortest Job Next
Priority Scheduling
Multilevel Queue Scheduling
In the context of operating systems, what is thrashing?
High CPU utilization
High paging activity
High disk utilization
High throughput
The E-R model is a:
Data definition language
High-level data model
Low-level data model
User interface
In a Max-Heap, the largest element can be found at which position?
Root
Leaf
Left child of root
Right child of root
Which register holds the address of the next instruction to be executed?
Accumulator
Program Counter
Instruction Register
Stack Pointer
Which normal form is considered as the "decomposed" version of a relation schema where all non-key attributes are fully functionally dependent on the primary key?
First Normal Form (1NF)
Second Normal Form (2NF)
Third Normal Form (3NF)
Boyce-Codd Normal Form (BCNF)
Which of the following is a valid SQL constraint?
SELECT
JOIN
UNIQUE
GROUP BY
The process of translating a high-level language program into machine code is called:
Assembling
Compiling
Interpreting
Linking
Which of the following search algorithms is optimal and complete?
Depth-First Search
Breadth-First Search
Hill Climbing
Genetic Algorithm
What is the time complexity to search for an element in a balanced binary search tree?
O(n)
O(log n)
O(n log n)
O(1)
A flip-flop is a:
Combinational circuit
Sequential circuit
Arithmetic circuit
Memory chip
In a computer system, which of the following is the fastest memory?
RAM
Cache
Hard Disk
Register
Intermediate code generation is done in which phase of the compiler?
Lexical Analysis
Syntax Analysis
Semantic Analysis
Code Optimization
A graph with no cycles is known as:
Tree
Complete Graph
Bipartite Graph
Multigraph
What does SSL stand for in the context of network security?
Secure Sockets Layer
Secure System Layer
Secure Shell Layer
Secure Software Layer
What is the goal of clustering in machine learning?
To classify data into predefined categories
To group similar data points together
To reduce the dimensionality of the data
To predict continuous values
Which of the following is not a type of addressing mode?
Immediate Addressing
Direct Addressing
Indirect Addressing
Procedural Addressing
The set of all subsets of a set S is called the:
Power set
Superset
Subset
Universal set
Which of the following is a universal gate?
AND
OR
NOT
NAND
Which HTTP method is used to request data from a specified resource?
POST
GET
PUT
DELETE
What does the acronym AJAX stand for?
Asynchronous JavaScript and XML
Advanced JavaScript and XML
Adaptive JavaScript and XML
Asynchronous JSON and XML
Which algorithm is commonly used for classification problems?
K-means
Linear Regression
Decision Tree
Principal Component Analysis
In a compiler, the parser is responsible for:
Generating the object code
Scanning the input
Checking the syntax
Optimizing the code
Which of the following is an example of a supervised learning algorithm?
K-means clustering
Decision Trees
Apriori algorithm
Genetic algorithms
In set theory, the intersection of two sets A and B is:
A ∪ B
A ∩ B
A - B
A Δ B
Which of the following is a symmetric key encryption algorithm?
RSA
ECC
AES
DSA
In CSS, which property is used to change the text color of an element?
color
background-color
text-color
font-color
In public-key cryptography, the public key is used for:
Decryption
Encryption
Both encryption and decryption
Key generation
Which of the following is not a type of parser?
Top-down parser
Bottom-up parser
Left-recursive parser
Recursive descent parser
A language is regular if and only if it can be accepted by a:
Finite Automaton
Pushdown Automaton
Turing Machine
Linear Bounded Automaton
Which of the following is not a type of malware?
Virus
Worm
Firewall
Trojan Horse
Which of the following is used to reduce the discrepancy between the speed of CPU and memory?
DMA
Cache
SSD
Virtual Memory
In the context of neural networks, what is an epoch?
A single iteration over the entire training dataset
A single pass through one batch of data
A measure of model accuracy
A type of activation function
The first phase of a compiler is:
Syntax Analysis
Lexical Analysis
Semantic Analysis
Code Generation
The Turing test is used to determine:
The efficiency of an algorithm
The intelligence of a machine
The correctness of a program
The complexity of a problem
The process of reducing the number of features in a dataset is known as:
Feature scaling
Feature selection
Feature engineering
Feature extraction
In artificial intelligence, which search algorithm is complete but not optimal?
Depth-First Search
Breadth-First Search
Uniform Cost Search
A* Search
In JavaScript, which of the following is not a valid data type?
String
Boolean
Character
Number
The concept of "utility" in AI refers to:
The efficiency of an algorithm
The cost of an action
The measure of satisfaction
The time complexity
Which of the following data structures is most suitable for implementing a LRU cache?
Stack
Queue
Hash Map + Doubly Linked List
Array
Which of the following is a common method for preventing overfitting in machine learning models?
Increasing the model complexity
Decreasing the training data size
Using regularization techniques
Using a single training dataset
Which of the following is used to verify the integrity of data?
Encryption
Hash Function
Digital Signature
Public Key
A grammar that is free from left recursion and left factoring is known as:
Context-Free Grammar
Context-Sensitive Grammar
LR Grammar
LL Grammar
In neural networks, what is backpropagation used for?
To initialize the weights
To train the network
To activate neurons
To collect the output
Which of the following is not a valid HTML tag?
