![]() |
VOOZH | about |
JPMC OnCampus Drive had 3 rounds
The JPMC OnCampus Drive had 3 Rounds:
1. The Coding Round
2. Video Round
3. Code For Good Round
In the First Round(Coding Round), the test was conducted in hackerrank and consists of two question which were very easy. People who solve atleast 1 problem is selected to the next round
Here are few questions which appeared in my test as well as my friends
Problem 1: Is Possible
Consider a pair of intergers (a,b). The following operations can be performed on a,b in any order, zero or more times
* (a,b) -> (a+b,b)
*(a,b)-> (a,a+b)
Return a string that denotes whether or not (a,b) can be converted to (c,d) by performing the operation zero or more times
Solution: This Problem can be solve using Recurrsion or Dynamic Programming (Since Contrainst are very low I solved using Recurrsion)
Problem 2: Highly Profitable Months
The Stocks of a company are being surveyed to analyse the net profit of the company over a period
For an analysis parameter k, an interval of k concutive months is said to be hightly profitable if the values of the stock prices are strictly increasing for those months. Given the stock prices of the company for n months and the analysis parameter k find the number of highly profitable intervals.
Example : stockPrices=[5,3,5,7,8], K=3
Here the answer is 2
Solution: Here the simple traversal would work,
Problem 3: Break a Palindrome
A palindrome reads the same from left to right and right to left, e.g., "mom" is a palindrome. You are given a palindrome string that must be modified if possible. Your task is to change exactly one character in the string to another character from the range 'a' to 'z' (both inclusive) so that the string meets the following three conditions:
If there is no valid way to modify the palindrome string, return the string "IMPOSSIBLE".
Solution: O(N) Time Complexity with single traversal
Problem 4: Minimum Total Cost of Reducing an Array to One Element
You are given an array nums of n integers. The array can be reduced by 1 element by performing a move. Each move consists of the following three steps:
num1 and num2 from the array.Each move has a cost associated with it: the sum of the two elements removed from the array during the move. Your task is to calculate the minimum total cost of reducing the array to one element.
Solution: Using Min Heap we can solve (STL)
Problem 5: Find the Longest Even Word
You are given a string sentence, consisting of words separated by spaces. Each word is a substring consisting of English alphabetic letters only. Your task is to find the first word in the sentence that has a length which is both an even number and greater than or equal to the length of any other word of even length in the sentence. If there are multiple words meeting the criteria, return the one which occurs first in the sentence.
Solution: Easy
Problem 6: Find Missing Words as Subsequence
Given two strings s and t, s being the original string, and t being a subsequence of s, your task is to find the words missing in t (case sensitive) and return them in order.
A subsequence of a string occurs when all letters of the first string (s) occur in the same order with the second string (t). The words in the strings are space-delimited.
Problem 7: Binary Sorting
You are given an array of decimal integers. Rearrange the array according to the following rules:
There are many Questions On Arrays, Strings and Math based. In my experience it the qualifier rund is very easy to clear
Round 2: Video Round:
There will be Two Question asked, Both have to be answered within 2 mins and you will be given 30 sec preparation time after the question is displayed. These questions would be same for every one in your college. Mostly these questions would be like HR Questions, Not the DSA once
Round 3: CodeForGood
This year, Code for Good was conducted physically at the JPMC Campus. Participants were given real-life problem statements to work on. The winning team of Code for Good will have the opportunity to be considered for an SDE (Software Development Engineer) role, based on their performance. Additionally, other teams also have a chance of being selected if they have performed well and impressed their mentor