Tip 1 : Practice at least 250 Questions
Tip 2 : Do at least 2 projects
Tip 3 : Develop problem solving skills
Tip 1 : Have some projects on resume.
Tip 2 : Do not put false things on resume.
I got a email. The email contained a link to an online assessment that I was asked to complete within a certain time frame.
The assessment was comprised of several coding exercises and multiple-choice questions related to software development and programming languages. I completed the assessment and felt that I had done well, based on my experience and preparation.
Which of the following data structures is best suited for implementing a priority queue?
A heap is a binary tree-based data structure in which each node has a priority value and satisfies the heap property, which ensures that the root node has the highest priority. This allows for efficient insertion and removal of elements with the highest priority. Priority queues are commonly used in scheduling and resource allocation systems where jobs or tasks have different priorities.
Which of the following is not a type of join in SQL?
Which of the following algorithms is used to prevent deadlocks in Operating Systems?(Learn)
Index join is not a type of join in SQL. The commonly recognized types of join in SQL are Inner Join, Left Join, Right Join, and Full Join.
Lock, Turn, Mutexes are used to solve deadlock problem in OS.



1. The processes are numbered from 1 to 'N'.
2. The process with lowest arrival time will be scheduled first, followed by the next lowest arrival time, and so on.
3. If any two processes have the same arrival time, then you have to run the process based on the priority of the process. The highest priority process will be scheduled first, followed by the next highest priority, and so on.
4. If the two processes have the same priority, then you have to run the process with the lowest process number first.



1. Push(num): Push the given number in the stack if the stack is not full.
2. Pop: Remove and print the top element from the stack if present, else print -1.
3. Top: Print the top element of the stack if present, else print -1.
4. isEmpty: Print 1 if the stack is empty, else print 0.
5. isFull: Print 1 if the stack is full, else print 0.
We perform the following operations on an empty stack which has capacity 2:
When operation 1 1 is performed, we insert 1 in the stack.
When operation 1 2 is performed, we insert 2 in the stack.
When operation 2 is performed, we remove the top element from the stack and print 2.
When operation 3 is performed, we print the top element of the stack, i.e., 3.
When operation 4 is performed, we print 0 because the stack is not empty.
When operation 5 is performed, we print 0 because the stack is size 1, which is not equal to its capacity.
In this program, we define a Stack class that encapsulates the stack data structure. The stack is implemented as an array of integers, with a maximum size of 10 elements.
The Stack class provides three public member functions: push(), pop(), and peek(). The push() function adds an element to the top of the stack, the pop() function removes the top element from the stack, and the peek() function returns the top element without removing it.
In the main() function, we create a Stack object and add three elements to it using the push() function. We then print the top element of the stack using the peek() function, and remove it from the stack using the pop() function. We repeat this process until the stack is empty.
This program demonstrates how a stack data structure can be implemented using an array in C++.



You must write an algorithm whose time complexity is O(LogN)
In this program, we define the binarySearch() function that implements the binary search algorithm. The function takes four arguments: the array to be searched (arr), the lower and upper bounds of the search range (low and high), and the key value to be searched for (key).
The binary search algorithm works by repeatedly dividing the search range in half until the element is found or the range is exhausted. In each iteration, the function calculates the middle index of the range (mid) and compares the element at that index to the key value. If the element is equal to the key, the function returns the index. If the element is less than the key, the function continues the search in the upper half of the range. If the element is greater than the key, the function continues the search in the lower half of the range.
In the main() function, we define an example array and a key value to be searched for. We then call the binarySearch() function with the appropriate arguments, and print the index of the element if it is found, or an error message if it is not found.
This program demonstrates how the binary search algorithm can be implemented in C++.
SQL query in MySQL that demonstrates how to join two tables based on a common column:
SELECT orders.order_id, customers.name, customers.email, orders.order_date
FROM orders
INNER JOIN customers
ON orders.customer_id = customers.customer_id;



Input: 'arr' = [1, 2, 7, -4, 3, 2, -10, 9, 1]
Output: 11
Explanation: The subarray yielding the maximum sum is [1, 2, 7, -4, 3, 2].
def max_subarray_sum(arr):
max_sum = float('-inf')
cur_sum = 0
for num in arr:
cur_sum += num
max_sum = max(max_sum, cur_sum)
cur_sum = max(cur_sum, 0)
return max_sum
This function uses a modified Kadane's algorithm to find the maximum sum of any contiguous subarray. The algorithm works by iterating through the array and keeping track of the current sum of the subarray. If the current sum becomes negative, the algorithm resets the current sum to zero, since any subarray that includes the negative number will have a smaller sum. At each iteration, the algorithm also updates the maximum sum seen so far.
The time complexity of this algorithm is O(n), where n is the length of the input array, since the algorithm only iterates through the array once.
What motivated you to pursue a career in software development, and what led you to specialize in your particular area of expertise?
I have always been interested in technology and problem-solving, which led me to pursue a career in software development. I specialize in [particular area of expertise] because it aligns with my interests and skills, and I enjoy the challenges and opportunities for innovation that it offers.
Could you describe a particularly challenging project that you've worked on in the past, and how you overcame any obstacles that arose during the development process? Additionally, what did you learn from that experience that you think has helped you grow as a software developer?
One project that comes to mind is in that. We faced several obstacles during the development process, including [briefly describe obstacles]. To overcome these challenges, we [briefly describe solution]. This experience taught me the importance of clear communication, collaboration, and adaptability in software development, and it helped me develop my problem-solving skills and ability to work under pressure.

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