BlackRock Interview Questions
104 real interview questions at BlackRock.
Showing 31–60 of 104 questions
Reverse the nodes of a linked list.
Arrange an array so that all zeros are on one side and all ones are on the other side.
Write a function that reverses a string.
Explain the use of the static keyword in the context of Java. What does it mean when a variable or method is declared static?
What is the difference between an interface and an abstract class in Java? How does method overloading differ from method overriding? Can you explain the concept of encapsulation? What is the purpose of the 'final' keyword in Java?
Write the bubble sort algorithm.
Implement an isEqual function to compare two objects and determine if they are equal.
What data structure would you use to build a parking lot, and why?
Sort a stack using only one additional stack and a single variable.
Find the first common ancestor of two given nodes in a tree.
How does a HashMap work internally?
Describe how a HashMap works.
1. Reverse a string in place. 2. Write a method that converts a decimal number to binary. 3. What is a Singleton? 4. What are the differences between Array and ArrayList in Java? 5. If you were to design a phone directory, what data structure would you use? 6. Calculate Fibonacci numbers with and without recursion; for example, given an array [3, 5, 4], return the 3rd, 5th, and 4th Fibonacci numbers in an array. What is the complexity of your algorithm? 7. Return the length of the last word in a sentence. For example: String s = "Hello Wang" should return 4; String s2 = "Hello " should return 5; String s3 = "" should return 0. 8. Given a number greater than 9, write a program that repeatedly sums its digits until the result is less than 10 (e.g., 38 → 3+8=11, then 1+1=2, stop). 9. What are the differences between String, StringBuilder, and StringBuffer in Java?
How does a HashMap find an entry, and what is the runtime complexity of that search operation?
Why is multiple inheritance not supported in Java?
Given an array of integers (both positive and negative), find the maximum sum of consecutive integers.
Implement a resizable stack data structure in your preferred programming language.
Write a function that takes a string and an integer as inputs. The integer specifies the maximum number of consecutive repeated letters to allow in the returned string. For example: ('aab', 1) -> 'ab'; ('aaabba', 2) -> 'aabba'.
Write a method to perform binary search on a sorted array.
How do you convert an expression in infix (prefix) notation to postfix notation?
Find the least common ancestor of two given nodes in an N-ary tree.
In Java, how would you create a deck of cards and implement a method to shuffle them?
How do you detect a cycle in a circular linked list?
1. Write an SQL query to find the second largest entry in a table. 2. Reverse the words in a sentence without using another string.
What is the angle between the hour hand and the minute hand of a clock at 3:15?
What is convexity? How is it calculated? What does it tell you?
What is the Black-Scholes option pricing model?
Design a cache system that stores key-value pairs with a fixed capacity. When the cache reaches its limit, it should evict the least recently used (LRU) entry. Implement methods to get a value by key, set a new key-value pair, and delete a specific key from the cache using a data structure of your choice.
Explain valuation techniques for pricing mortgage and corporate bonds.
How do you find the number of words in a file?
Want the full solutions?
Get detailed walkthroughs for all 104+ BlackRock questions with Quant Blueprint.
Get Started