wayground logo

Free Printable Worksheets

NEW

Font size

S
M
L
XL
Worksheets

Pre_Place_Batch_2027_SET_F

Total questions: 40

Worksheet time: 40mins

Name
Class
Date
1.
Which property of a transaction ensures that all operations within the transaction are completed successfully, or none of them are?
a)
Atomicity
b)
Consistency
c)
Isolation
d)
Durability
2.
The durability property of a transaction ensures that:
a)
Changes made by a transaction are not permanent
b)
Changes are visible even before the transaction is committed
c)
Once a transaction commits, its changes are lost on system failure
d)
Once a transaction commits, its changes are permanent, surviving system failures
3.
Which of the following is NOT a property of transactions (ACID properties)?
a)
Authenticity
b)
Atomicity
c)
Consistency
d)
Isolation
4.
In the context of transactions, what does the consistency property ensure?
a)
The database remains in a consistent state before and after the transaction
b)
The transaction only shows committed data to external users
c)
Transactions are isolated from each other
d)
The results of the transaction are permanently stored in the database
5.
Isolation in database transactions ensures that:
a)
Transactions are processed in a linear fashion
b)
The operations of one transaction are visible to another transaction
c)
Multiple transactions can be made to appear as if they are running in parallel
d)
Each transaction is aware of all other transactions in the system
6.
The process of minimizing redundancy and dependency by organizing fields and table relationships is known as:
a)
Denormalization
b)
Normalization
c)
Indexing
d)
Partitioning
7.
Which normal form is concerned with removing partial dependency between columns of a database table?
a)
1NF
b)
2NF
c)
3NF
d)
BCNF
8.
A relation R is in which normal form if every non-prime attribute of R is non-transitively dependent on every key of R?
a)
First Normal Form (1NF)
b)
Second Normal Form (2NF)
c)
Third Normal Form (3NF)
d)
Boyce-Codd Normal Form (BCNF)
9.
Lossless join property ensures that:
a)
The join operation increases data redundancy
b)
Data can be reconstructed exactly after decomposition
c)
Data is lost during normalization
d)
The join operation reduces query performance
10.
Given the following SQL statement: SELECT Name FROM Employees WHERE DepartmentID IN (SELECT DepartmentID FROM Departments WHERE Budget > 100000); What does this query do?
a)
Retrieves the names of all employees who work in departments with a budget greater than 100000
b)
Deletes names of employees in departments with high budgets
c)
Updates the names of employees in well-funded departments
d)
Inserts names into Employees for departments with large budgets
11.
How do you determine the cost of a spanning tree?
a)
By the sum of the costs of the edges and vertices of the tree
b)
By the sum of the costs of the edges of the tree
c)
By the sum of the costs of the vertices of the tree
d)
By the sum of the costs of the edges of the graph
12.
The time complexity of the normal quick sort, randomized quick sort algorithms in the worst case is
a)
O(n^2), O(n log n)
b)
O(n^2), O(n^2)
c)
O(n log n), O(n^2)
d)
O(n log n), O(n log n)
13.
The Sorting methodwhich is used for external sort is
a)
Bubble Sort
b)
Quick Sort
c)
Merge Sort
d)
Radix Sort
14.
In analysis of algorithm, approximate relationship between the size of the job and the amount of work required to do is expressed by using _________
a)
Central tendency
b)
Differential equation
c)
Order of execution
d)
Order of magnitude
15.
Consider the usual algorithm for determining whether a sequence of parentheses is balanced. What is the maximum number of parentheses that will appear on the stack AT ANY ONE TIME when the algorithm analyzes: (()(())(()))
a)
1
b)
2
c)
3
d)
4
16.
Breadth first search __________
a)
Scans each incident node along with its children.
b)
Scans all incident edges before moving to other node.
c)
Is same as backtracking
d)
Scans all the nodes in random order.
17.
Which method of traversal does not use stack to hold nodes that are waiting to be processed?
a)
Depth First
b)
D-search
c)
Breadth First
d)
Back-tracking
18.
Convert the following infix expression into prefix expression: ( A + B ) * ( C + D )
a)
A B + C D + *
b)
+ + A * B C D
c)
* + A B + C D
d)
A B C * + D +
19.
Evaluate the postfix expression 6 5 2 3 + 8 * + 3 + *
a)
312
b)
288
c)
302
d)
308
20.
In an empty BST, insert the following elements in a similar sequence. Which element will be at the lowest level? 105, 95, 122, 99, 97, 120
a)
95
b)
97
c)
99
d)
120
21.
Consider a stack of integers. The stack is allocated 5 memory cells. STACK : 1, 3, 3, _, _ The following operations are performed on the stack : i) PUSH(STACK,4) ii) PUSH(STACK,10) iii) POP(STACK,ITEM) What value will be stored in ITEM?
a)
1
b)
10
c)
4
d)
3
22.
In a system, if two classes are dependent on each other, it increases:
a)
Loose coupling
b)
Encapsulation
c)
Tight coupling
d)
Delegation
e)

None of the mentioned

23.
What would you use when you want to delay the creation of an object until it's actually needed?
a)
Factory pattern
b)
Singleton
c)
Lazy initialization
d)
Proxy
e)
Abstract factory
24.
Your application has a class with 15 public methods and 3 private variables. The class is very hard to test. What could improve it?
a)
Make all variables public
b)
Split it based on functionality
c)
Inherit it from a utility class
d)
Convert to interface
e)
Remove private methods
25.
A developer uses final keyword in Java to prevent subclassing a class. Which OOP principle is being enforced?
a)
Polymorphism
b)
Encapsulation
c)
Abstraction
d)
Restriction of inheritance
e)
Overloading
26.
Which of the following best describes "dynamic polymorphism"?
a)
Compile-time method binding
b)
The ability to create dynamic classes at runtime
c)
Method overriding where method calls are resolved at runtime
d)
The creation of objects at runtime
27.
Instance of which type of class can’t be created?
a)
Parent Class
b)
Abstract class
c)
Anonymous Class
d)
Nested class
28.
What happens if non static members are used in static member function?
a)
Executes fine
b)
Compile time error
c)
Executes if that member function is not used
d)
Runtime error
e)

None of the mentioned

29.
What is encapsulation in OOP?
a)
It is a way of combining various data members and member functions that operate on those data members into a single unit
b)
It is a way of combining various data members and member functions into a single unit which can operate on any data
c)
It is a way of combining various data members into a single unit
d)
It is a way of combining various member functions into a single unit
e)

Data Sharing

30.
The feature by which one object can interact with another object is _____________
a)
Message reading
b)
Message Passing
c)
Data transfer
d)
Data binding
e)

Encapsulation

31.
Which CAP theorem property is sacrificed in a highly available distributed system during a network partition?
a)
Consistency
b)
Durability
c)
Atomicity
d)
Isolation
32.
Which database is most suitable for handling highly connected data such as social networks?
a)
Relational DB
b)
Key-value store
c)
Graph database
d)
Columnar database
33.
Your video streaming platform wants to minimize latency for global users. Which solution provides the highest impact?
a)
Vertical scaling
b)
Database indexing
c)
Content Delivery Network (CDN)
d)
Strong consistency
34.
A chat application requires message ordering per user but not across all users. Which consistency model fits best?
a)
Strong consistency
b)
Linearizability
c)
Causal consistency
d)
Eventual consistency
35.
Predict the Output: s="abcd" for i from 0 to length(s)-1: if i%2==0: print s[length(s)-1-i]
a)
da
b)
d b
c)
d c
d)
d a
36.
Predict the Output: x=0 for i=1 to 4: if(i%2==0) continue x+=i print(x)
a)
4
b)
5
c)
6
d)
10
37.

Predict the Output:

int[] nums = {12, 5, 8, 20, 3};

int val = nums[0];

for (int i = 1; i < nums.length; i++) {

if (nums[i] > val) {

val = nums[i]; } }

a)
Finds the sum of the array.
b)
Finds the minimum value.
c)
Finds the maximum value.
d)
Sorts the array.
38.

Predict the Output:

arr = [ [2, 1, 4], [6, 3, 5], [7, 8, 9] ]

sum = 0

for i = 0...2:

for j = 0...2:

if arr[i][j] % (i+1) == 0:

sum = sum + arr[i][j]

print sum

a)
15
b)
22
c)
45
d)
18
39.

What is the primary purpose of generating questions in a learning environment?

a)

To entertain students

b)

To assess knowledge

c)

To confuse learners

d)

To increase workload

40.

In educational settings, what type of questions are often generated to encourage critical thinking?

a)

Open-ended

b)

True/false

c)

Multiple choice

d)

Fill in the blanks