Code Pumpkin

Morgan Stanley Interview Questions – Set 6

October 8, 2017
Posted by Pumpkin

I have appeared for Sr Java Developer position at Synechron Technologies. I cleared three F2F interview rounds of Synechron. I had also cleared two telephonic rounds with Synechron's client Morgan Stanley.

After that I was invited for last two F2F rounds with Morgan Stanley at Bangalore. Overall experience was very good. Synechron has provided TO and FRO flight tickets from Ahmedabad to Bangalore as well as Cab for full day transportation in Bangalore.

First F2F interview with Morgan Stanley

  1. Tell me about your current project and technologies you have worked on.
  2. What is the difference between fail-safe and fail-fast iterators?
  3. Write a program to implement LRU Cache.
  4. Write a program to implement stack which always maintains pointer to minimum element of the stack. You can use push() and pop() methods of jdk Stack Implementation.
  5. How to read multiple files from one specific location on the memory using multiple threads? At a time maximum 10 threads should read different files concurrently.
  6. What all design patterns have u worked on?
  7. Write a program for Observer Design Pattern.
  8. Suppose you have a table with no primary key. There are duplicate records in that table. Write a SQL query to  remove unnecessary duplicate records.
  9. Suppose you have below account_table
Account_Id Transaction_Type Amount
100 Credit 2000
100 Debit 300
100 Credit 99
101 Credit 500

Write a query to fetch result as below

Account_Id Net_Balance
100 1799
101 500

select Account_Id,
      Sum(Decode(Transaction_Type, 'Credit', Amount, 'Debit', -Amount)) "Net_Balance"
from Account_table
group by Account_Id;
  1. What do u use for Unit Testing in your project? 
  2. Which mocking frameworks have u used for JUnit testing?

Second F2F interview with Morgan Stanley

  1. Introduce yourself.
  2. Tell me about your current project.
  3. Tell me about your greatest achievement in your current project.
  4. When it is recommanded to use fail-safe iterators over fail-fast iterators.
  5. What are the pros and cons of Hibernate over Spring JDBC?
  6. Which tool do you use in current project to identify performance related issues?
  7. How will you identify the cause of OutOfMemoryErrors in your application? 
  8. When is it recommended to change the JVM configuration to avoid OutOfMemory error?
  9. Write a program to implement Producer Consumer Design Pattern.
  10. Write a program to evaluate a given mathematical expression.

For Example,
    1 + 2 * 3                 Answer : 7 
    1 + 2 – 3                 Answer : 0
    4 / 4 * 4                  Answer : 4
    
Note :
* and / has equal precedence. 
+ and – has equal precedence.
Assume that * and / has greater precedence over + and -.
if two operators have equal precedence, then operator on the left side should be given a priority.


This article is contributed anonymously by one of the CodePumpkin user. If you would also like to contribute your article or share interview experiences, you can create contributor account with CodePumpkin by clicking here or you can send us a mail at admin@codepumpkin.com.

That's all for this topic. If you guys have any suggestions or queries, feel free to drop a comment. We would be happy to add that in our post. You can also contribute your articles by creating contributor account here.

Happy Learning 🙂

If you like the content on CodePumpkin and if you wish to do something for the community and the planet Earth, you can donate to our campaign for planting more trees at CodePumpkin Cauvery Calling Campaign.

We may not get time to plant a tree, but we can definitely donate ₹42 per Tree.



About the Author


A Blog that will help you to learn and refresh your knowledge on Core Java, Data Structure, algorithms, Design Patterns.



Tags: , , , , , , ,


Comments and Queries

If you want someone to read your code, please put the code inside <pre><code> and </code></pre> tags. For example:
<pre><code class="java"> 
String foo = "bar";
</code></pre>
For more information on supported HTML tags in disqus comment, click here.
Total Posts : 124
follow us in feedly

Like Us On Facebook