16 questions · from 3 interviews

Demandbase interview questions

Every question candidates reported from their Demandbase interviews, most frequently asked first. Each links to the write-up it came from, so you can see the round and how it went.

Demandbase coding and DSA questions

  1. 01

    Multi-Source BFS (similar to Rotting Oranges)

    The coding problem required implementing a multi‑source breadth‑first search on a graph. You start BFS simultaneously from multiple source nodes (initialize the queue with all sources) and explore the graph level by level. The expected solution follows the…

    Medium · From DemandBase Interview Experience - on-campus for SDE Intern + PPO chance

  2. 02

    Parallel Courses III

    Given a set of courses, each with a duration (in months) and a list of prerequisite courses, determine the minimum number of months required to complete all courses. The problem can be modeled as a directed acyclic graph where nodes represent courses and…

    Hard · From DemandBase Interview Experience - on-campus for SDE Intern + PPO chance

  3. 03

    HashMap Internal Working and Time Complexity

    Discuss the internal working mechanism of a HashMap in Java, including how values are stored, collision resolution strategies, and the average and worst-case time complexities for common operations like put() and get().

    Medium · From Demand Base | Interview Experience | 4 yrs experience

  4. 04

    Maximum Product of Three Numbers

    Given an integer array, find three numbers whose product is maximum and return the maximum product. Discuss various edge cases, such as arrays with negative numbers or arrays shorter than three elements.

    Easy · From Demand Base | Interview Experience | 4 yrs experience

  5. 05

    Lowest Common Ancestor of a Binary Tree

    Write code to find the lowest common ancestor (LCA) of two given nodes in a binary tree. Assume both nodes exist in the tree and are unique.

    Medium · From Demand Base | Interview Experience | 4 yrs experience

  6. 06

    Minimum Operations to Convert String S1 to S2 (Extended Edit Distance)

    Given two strings, s1 and s2, find the minimum number of operations required to convert s1 to s2. Allowed operations include: Replace, Add, Delete, Swap (adjacent characters), and Substitute (single character replacement). The exact definitions of 'Swap' and…

    Hard · From Demand Base | Interview Experience | 4 yrs experience

  7. 07

    Merge k Sorted Lists

    Merge k sorted linked lists into one single sorted linked list. Implement the solution using a priority queue.

    Hard · From Demand Base | Interview Experience | 4 yrs experience

  8. 08

    Search in Rotated Sorted Array

    I was asked to find an element in a rotated sorted array. I had to write the code in a shared Google Doc.

    Medium · From DemandBase (Java SSE, 4yoe)

  9. 09

    Longest Palindromic Subsequence

    I was tasked with finding the longest palindromic subsequence. I initially presented a recursive approach, discussing its time and space complexity. Following that, I explained a memoization approach and again discussed its time and space complexity.

    Medium · From DemandBase (Java SSE, 4yoe)

Demandbase system design questions

  1. 01

    Design a Multi-Floor Parking System

    Design a low‑level system for a multi‑floor parking garage. Identify core entities such as ParkingLot , Floor , Slot , Vehicle , and Ticket . Define their relationships, responsibilities, and interactions. Consider handling different vehicle types, slot…

    From DemandBase Interview Experience - on-campus for SDE Intern + PPO chance

Demandbase other questions

  1. 01

    Difference between Final, Finalize, and Finally

    Explain the differences between the final keyword, the finalize() method, and the finally block in Java.

    From Demand Base | Interview Experience | 4 yrs experience

  2. 02

    Custom Hashing for HashMap Key

    Given the following CustomKey class, predict the output of the System.out.print statement. Then, write the logic (implement hashCode() and equals() methods) within the CustomKey class to ensure HashMap correctly retrieves the value for a matching key. java…

    Medium · From Demand Base | Interview Experience | 4 yrs experience

  3. 03

    Authentication vs. Authorization

    Explain the key differences between authentication and authorization in the context of system security.

    From Demand Base | Interview Experience | 4 yrs experience

  4. 04

    Purpose of doFilter in Java Servlets

    Explain the purpose and usage of the doFilter method within a Java Servlet Filter. Describe its role in the request processing lifecycle.

    From Demand Base | Interview Experience | 4 yrs experience

  5. 05

    Java Pass by Value/Reference and Object Mutation

    Given the CustomKey class (as defined previously) and the following methods, determine the output of sout(a.id) after each method call. Discuss the concepts of pass-by-value and how objects are handled in Java method calls. java CustomKey a = new CustomKey(1,…

    Easy · From Demand Base | Interview Experience | 4 yrs experience

  6. 06

    Core Java Concepts: Virtual, Atomic, Callable vs. Comparator

    I was asked to explain the concepts of 'virtual' and 'atomic' in Java, and elaborate on the differences between Callable and Comparator interfaces.

    From DemandBase (Java SSE, 4yoe)

Demandbase interview questions FAQ

What questions are asked in Demandbase interviews?

Candidates reported 16 distinct questions across 3 Demandbase interviews. 9 coding and DSA questions, 1 system design questions, 6 other questions.

How difficult are Demandbase interview questions?

Of the questions candidates rated, 18% were easy, 55% medium and 27% hard.