Interview Experience At MoEngage

Posted
5 Dec 2025
475 reads

Summary

I recently interviewed at MoEngage, which included an in-depth discussion on Kafka internals and a challenging machine coding round focused on designing a Stock Price Volatility Monitor using a sliding window.

How it went

I recently had an interview at MoEngage. The initial phase delved into a comprehensive discussion about Kafka, covering essential topics such as producers, consumers, consumer groups, offset management, partitions, message ordering, backpressure handling, and ensuring Kafka's exactly-once semantics. We also explored Kafka internals in detail, including log compaction, retry mechanisms, and idempotency. Following this in-depth technical discussion, I proceeded to a machine coding round.

Questions asked (1)

  1. 01

    Stock Price Volatility Monitor

    Data Structures & Algorithms · Medium

    You are given a continuous stream of stock price changes (both positive and negative).

    Your task is to design a VolatilityMonitor class that keeps track of the maximum volatility within the last N trades.

    👉 Volatility = absolute value of price change

    You must implement two methods:

    1. recordTrade(int priceChange)
      • Adds a new trade.
      • Only the last N trades are stored — so this forms a sliding window.
    2. getMaxVolatility() → int
      • Returns the maximum absolute price change in the current sliding window.

    📘 Example

    Let tradeWindow = 3
    

    Operation Window Max Volatility recordTrade(5) [5] 5 recordTrade(-3) [5, -3] 5 recordTrade(8) [5, -3, 8] 8 recordTrade(2) [-3, 8, 2] 8

    The window always slides to keep only the last N price changes.

Know someone preparing? Send it to them:WhatsAppLinkedInX

Interviewed at Moengage 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!