Bloomberg SSE screen round

Posted
26 Feb 2026
380 reads

Summary

I had a screening round for a role at Bloomberg. The interview involved introductions, a behavioral question about a difficult production issue, and two coding problems: validating a binary search tree and implementing a Trie to find words with a matching prefix. Despite my attempts, I was rejected due to mistakes in my Trie implementation.

How it went

1. Introductions (10 mins)


2. Tell me about the most difficult production issue you faced and how you solved it. (10 mins)

3. validate binary search tree -> done with coding in 5 mins

4. given a dictionary of words, find all words having matching prefix

import java.io.*;
import java.util.*;
import java.text.*;
import java.math.*;
import java.util.regex.*;

class Dictionary { TrieNode root;

public Dictionary() {
    this.root = new TrieNode('\0');
}

public void add(String word) {
    TrieNode current = root;
    for (int i = 0; i < word.length(); i++) {
        Character key = word.charAt(i);
        if (root.next.containsKey(key)) {
            current = root.next.get(key);
        } else {
            TrieNode newNode = new TrieNode(key);
            root.next.put(key, newNode); // mistake -> should have been current
            current = newNode;
        }
    }
    current.isEnd = true;
    current.word = word;
}

public List<String> queryPrefix(String prefix) {
    List<String> res = new ArrayList<>();
    TrieNode current = root;
    for (int i = 0; i < prefix.length(); i++) {
        Character key = prefix.charAt(i);
        if (root.next.containsKey(key)) {
            current = root.next.get(key); // mistake -> should have been current
        }
        if (current.isEnd) {
            res.add(current.word);
        }
    }

    dfs(current, res);
    return res;
}

public void dfs(TrieNode root, List<String> res) {
    if (root == null)
        return;

    if (root.isEnd) {
        res.add(root.word);
    }

    for (Map.Entry<Character, TrieNode> entry : root.next.entrySet()) {
        dfs(entry.getValue(), res);
    }
}

}

public class Solution { public static void main(String[] args) { Dictionary dict = new Dictionary(); dict.add("abcdef"); dict.add("abcijk"); System.out.println(dict.queryPrefix("abc")); } }

// represents a dictionary // method 1 -> add a word to dictionary (a-z) // method 2 -> query method list of all the words that match with the given prefix

class TrieNode { Character c; HashMap<Character, TrieNode> next; String word; boolean isEnd;

public TrieNode(Character c) {
    this.c = c;
    this.next = new HashMap&lt;&gt;();
    this.isEnd = false;
}

}

Verdict : Rejected

Is the job market so brutal that even 2 lines of code cant be incorrect ?

Questions asked (3)

  1. 01

    Most Difficult Production Issue

    Behavioral

    Tell me about the most difficult production issue you faced and how you solved it.

  2. 02

    Validate Binary Search Tree

    Data Structures & Algorithms · Medium

    Validate a given Binary Search Tree (BST).

  3. 03

    Find Words with Matching Prefix using Trie

    Data Structures & Algorithms · Medium

    Given a dictionary of words, find all words having a matching prefix. You need to implement a Trie (prefix tree) to store the dictionary and provide a method to query words based on a given prefix.

Know someone preparing? Send it to them:WhatsAppLinkedInX

Interviewed at Bloomberg recently?

Write up your rounds while you still remember the questions. It helps the next person more than you would think.

Share your experience
Discussion 0

Questions for the author, or how your own interview compared.

Join the discussion

Sign in with Google to comment or ask the author a question.

No comments yet

Be the first to share your thoughts and start the discussion!