Tip 1 : Prepare Data Structures and Algorithms properly
Tip 2 : Practice of competitive coding platforms
Tip 3 : Practice questions related to Maths, Digit DP, HashMap, Greedy Algorithms, DP, Graph
Tip 1 : Mention those things only which are relevant
Tip 2 : Mention those skills only which you're aware of
This round happened at HackerEarth which consists of 3 coding questions which were of 50, 75, and 100 marks according to the difficulty which you need to solve in 3 hours. Those who were able to solve 1 or more than 1 question were selected for the next round.


1. The sizes will range from 1 to ‘N’ and will be integers.
2. The sum of the pieces cut should be equal to ‘N’.
3. Consider 1-based indexing.
First I tried to figure out the exact requirements and then tried brute force first but it shows TLE then I tried to optimize it and able to pass 48 out of 50 test cases.



You need to count occurrences at every place of the number. You also need to include the lower and higher limits of the given range
Given K = 3, A = 1, B = 15, then 3 occurs 2 times(3, 13) in the range [1, 15], so you need to print 2.



Input: 'arr' = [2, 2, 2, 2, 0, 0, 1, 0]
Output: Final 'arr' = [0, 0, 0, 1, 2, 2, 2, 2]
Explanation: The array is sorted in increasing order.
Tried to solve using Greedy Approach and 12 test cases passed out of 50
This round was also happened at HackerEarth and having the same pattern for 3 hours and 3 questions. In this round questions were mostly based on DP, Mathematics, and Graph.



It was basically logical question where you've to analyze the problem and test cases very carefully. After, proper analysis I was able to come up with approach



If the given graph is :

Then the edge between 0 and 4 is the bridge because if the edge between 0 and 4 is removed, then there will be no path left to reach from 0 to 4.and makes the graph disconnected, and increases the number of connected components.
There are no self-loops(an edge connecting the vertex to itself) in the given graph.
There are no parallel edges i.e no two vertices are directly connected by more than 1 edge.



Passed 6 test cases out of 50
This round takes place virtually on the Cisco Webex platform.
Is your project based on 2-tier architecture or 3-tier?
Tip 1 : Explain the project first
Tip 2 : Then tell the answer
Tip 3 : Then tell why your answer is correct
Tip 1 : Go through the OOPS concepts very carefully
Tip 2 : Read some books of your academics over OOPS
Tip 3 : Take the help from the internet



Implemented Linked List and sorted it by the conventional approach



Bubble Sort implementation for the given array: {6,2,8,4,10} is shown below :-
Written Code for Bubble Sort



Given ‘N’ = 2, The total number of BST’s is 2.

1. A binary search tree is a rooted binary tree whose internal nodes each store a key greater than all the keys in the node's left subtree and less than those in its right subtree.
2. A structurally unique binary search tree is a tree that has at least 1 node at a different position or with a different value compared to another binary search tree.
Tell him about binary search and applications

Here's your problem of the day
Solving this problem will increase your chance to get selected in this company
To make an AI less repetitive in a long paragraph, you should increase: