Tip 1: Practise writing SQL queries. Do not focus only on theory.
Tip 2: Practise programming questions from various online coding platforms.
Tip 3: Have a good command over core computer science subjects.
Tip 1: Keep at least two full-stack projects to showcase your end-to-end development skills.
Tip 2: Include your coding platform profiles, GitHub, and LinkedIn links in your resume to create a strong professional impression.
The 90-minute online assessment was conducted on the Mettl platform in a secure and monitored environment. A timer was visible throughout, and no screen switching was allowed. There was no interviewer, but the system tracked activity and issued warning messages if any unusual behaviour was detected. The assessment consisted of 15 MCQs and 2 coding problems.
You have 8 balls, one of which is heavier. Using a weighing balance, find the heavier ball in minimum attempts.
Tip 1: Break problems into smaller steps.
A clock shows the time as 3:15. What is the angle between the hour and the minute hand?
Tip 1: Think logically, not just mathematically.
Tip 2: Draw diagrams or write notes.
Two trains are 120 km apart and move towards each other at speeds of 60 km/h and 40 km/h. A bird starts flying from one train to the other at 80 km/h until the trains meet. Find the total distance covered by the bird.
There are 100 doors initially closed. A person toggles doors in the following way: toggles every door in the first pass, every 2nd door in the second pass, every 3rd in the third pass, and so on till the 100th pass. Which doors remain open?
Tip 1: Break problems into smaller steps.
A man walks 1 km south, 1 km east, and 1 km north and comes back to the same point. How is this possible?
Which scheduling algorithm may cause starvation?
SJF and Priority scheduling (non-preemptive).
Consider 3 processes with burst times 10, 5, and 8. Calculate the average waiting time using FCFS scheduling.
Order P1(10), P2(5), P3(8). WT = [0, 10, 15], Avg = (0+10+15)/3 = 8.33 ms.
Which of the following is not true about deadlock?
a) Mutual exclusion is a necessary condition
b) Hold and wait must exist
c) Circular wait must exist
d) Deadlock can always be resolved using FCFS
In demand paging, what happens on a page fault?
Which of the following is true about thrashing?
a) It increases CPU utilization
b) It occurs due to excessive paging
c) It reduces I/O time
d) It improves performance
Consider a relation R(A,B,C,D) with functional dependencies:
A → B, B → C. What is the highest normal form?
3NF (since transitive dependency exists).
Which of the following ensures atomicity in transactions?
a) Commit log
b) Checkpoint
c) Transaction log
d) Deadlock prevention
Transaction log
Given the SQL query:
SELECT name FROM Student WHERE marks > ALL (SELECT marks FROM Student WHERE dept = 'CSE');
What does it return?
Tip 1: Do practice for SQL queries.
Ans: Returns student(s) with marks greater than the highest marks in CSE.
Which of the following indexing techniques is used in databases for faster access?
a) Hashing
b) B+ Tree
c) Both a & b
d) None
Tip 1: Ensure to cover indexing techniques in databases.
In two-phase locking protocol, which problem can still occur?
a) Deadlock
b) Lost update
c) Dirty read
d) Non-repeatable read
Practice locking protocols.

Input: ‘n’ = 7 ‘k’ = 3
‘a’ = [1, 2, 3, 1, 1, 1, 1]
Output: 3
Explanation: Subarrays whose sum = ‘3’ are:
[1, 2], [3], [1, 1, 1] and [1, 1, 1]
Here, the length of the longest subarray is 3, which is our final answer.
1. Use a prefix-sum and a hashmap that maps prefix_sum → earliest_index. Initialize with {0: -1}.
2. Iterate i from 0 to n-1, update prefix_sum += arr[i].
3. Check if (prefix_sum - K) exists in the map. If yes, candidate length = i - map[prefix_sum - K]. Update max_len.
4. If prefix_sum is not already in the map, store map[prefix_sum] = i (store earliest index to maximize length).
5. After loop, return max_len (0 if no subarray found).



Height of a tree is the maximum number of nodes in a path from the node to the leaf node.
An empty tree is a height-balanced tree. A non-empty binary tree is a height-balanced binary tree if
1. The left subtree of a binary tree is already the height-balanced tree.
2. The right subtree of a binary tree is also the height-balanced tree.
3. The difference between heights of left subtree and right subtree must not more than ‘1’.
Input: Consider the binary tree given below:

Output: 'true'
Explanation:
Consider subtree at Node ( 7 )
Left subtree height is ‘0’ and right subtree height is ‘0’, the absolute height difference is ‘0-0 = 0’ and ‘0’ is not more than ‘1’ so subtree at Node ( 7 ) is a height-balanced binary tree.
Same for subtrees at Nodes ( 5, 6 ).
Consider subtree at Node ( 4 )
Left subtree height is ‘1’ and right subtree height is ‘0’, the absolute height difference is ‘1-0 = 1’ and ‘1’ is not more than ‘1’ so subtree at Node ( 4 ) is a height-balanced binary tree.
Same for subtree at Node ( 3)
Consider subtree at Node ( 2 )
Left subtree height is ‘2’ and right subtree height is ‘1’, the absolute height difference is ‘2-1 = 1’ and ‘1’ is not more than ‘1’ so subtree at Node ( 2 ) is a height-balanced binary tree.
Consider subtree at Node ( 1 )
Left subtree height is ‘3’ and right subtree height is ‘2’, the absolute height difference is ‘3-2 = 1’ and ‘1’ is not more than ‘1’ so subtree at Node ( 1 ) is a height-balanced binary tree.
Because the root node ( 1 ) is a height-balanced binary tree, so the complete tree is height-balanced.
1. Define recursive helper height(node) that:
a. Returns 0 if node is None.
b. Calls left = height(node.left). If left == -1 return -1 (propagate unbalanced).
c. Calls right = height(node.right). If right == -1 return -1.
d. If abs(left - right) > 1 return -1 (unbalanced).
e. Else return max(left, right) + 1 (height).
2. Main check: tree is balanced iff height(root) != -1.

Here's your problem of the day
Solving this problem will increase your chance to get selected in this company
What is recursion?