All Companies

BlackRock Interview Questions

50 real interview questions for Software Engineer roles at BlackRock.

Showing 31–50 of 50 questions

31

In Java, how would you create a deck of cards and implement a method to shuffle them?

Software EngineerSoftware Engineer
32

How do you detect a cycle in a circular linked list?

Software EngineerSoftware Engineer
33

Answer the following programming questions: 1) Reverse a number. For example, input: 9966, output: 6699. 2) Count occurrences of each word in a string. For example, input: "The lovely lady is looking lovely as all lady look lovely", output: The: 1, lovely: 3, lady: 2, is: 1, looking: 1, as: 1, all: 1, look: 1. 3) Swap two numbers without using a temporary variable. For example, input: a = 10, b = 20; output: a = 20, b = 10.

Software EngineerSoftware Engineer
34

Implement a solution to find the intersection node of two singly linked lists, starting from a brute-force approach to the most optimal solution. Also, implement the linked list data structure from scratch. Additionally, explain the differences between arrays and linked lists.

Software EngineerSoftware Engineer
35

Given a singly linked list, find and return the middle node of the list. If there are two middle nodes, return the second middle node.

Software EngineerSoftware Developer
36

What is object-oriented programming (OOP)? What is the difference between arrays and lists? How do you reverse an array?

Software EngineerSoftware Engineer
37

Given a binary search tree (BST) and a target value, find whether the element exists in the BST.

Software EngineerSoftware Developer
38

Write a function that returns the median of a list of numbers.

Software EngineerSoftware Engineer
39

Arrange an array so that all zeros are on one side and all ones are on the other.

Software EngineerSoftware Engineer
40

Explain the keyword 'static' in the context of Java. What is its purpose and how is it used?

Software EngineerSoftware Developer
41

Sort a stack using only one other stack and a single variable.

Software EngineerSoftware Engineer
42

Given a tree and two specified nodes, find their first common ancestor.

Software EngineerSoftware Engineer
43

1. Reverse a string in place. 2. Write a method to convert a decimal number to binary. 3. What is the Singleton pattern? 4. What are the differences between Array and ArrayList in Java? 5. If you are going 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 and store them 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 an input number greater than 9, write a program that repeatedly sums all its digits until the sum is less than 10. For example, given 38: 3+8=11, 1+1=2, stop. 9. What are the differences between String, StringBuilder, and StringBuffer in Java?

Software EngineerSoftware Engineer
44

Given an array of integers (both positive and negative), find the maximum sum of any consecutive subarray.

Software EngineerSoftware Engineer
45

How does a HashMap find an entry, and what is the runtime of that search?

Software EngineerSoftware Engineer
46

Implement a stack data structure that dynamically resizes its storage as elements are pushed and popped.

Software EngineerSoftware Engineer
47

Write a function that takes in a string and an integer n. The integer determines the maximum number of allowed repeated consecutive letters. For example, ('aab', 1) should return 'ab'. ('aaabba', 2) should return 'aabba'.

Software EngineerSoftware Engineer
48

Write a method that implements binary search.

Software EngineerSoftware Engineer
49

How do you convert an expression in infix (or prefix) notation to postfix notation?

Software EngineerSoftware Engineer
50

Find the least common ancestor of two nodes in an N-ary tree.

Software EngineerSoftware Engineer

Want the full solutions?

Get detailed walkthroughs for all 104+ BlackRock questions with Quant Blueprint.

Get Started