PracHub
QuestionsPremiumCoachesLearningGuidesInterview Prep
|Home/Coding & Algorithms/Meta

Compute 95th-percentile call concurrency

Last updated: Mar 29, 2026

Quick Overview

This question evaluates a candidate's ability to design scalable algorithms for computing the 95th-percentile of per-minute concurrent calls over a 24-hour window, testing competencies in streaming/event aggregation, de-duplication, percentile computation, and managing time and memory constraints.

  • Medium
  • Meta
  • Coding & Algorithms
  • Data Scientist

Compute 95th-percentile call concurrency

Company: Meta

Role: Data Scientist

Category: Coding & Algorithms

Difficulty: Medium

Interview Round: Onsite

Given N call sessions as half-open intervals [start, end) in UNIX seconds, design an algorithm to compute the 95th percentile of per-minute concurrent calls over the last 24 hours ending at 2025-09-01 00:00:00 UTC (i.e., minutes from 2025-08-31 00:00 to 2025-09-01 00:00). Requirements: (1) Input is an unsorted stream that may not fit in memory; (2) The same call_id may appear multiple times; treat duplicate intervals as one after de-duplication by (start,end); (3) A call active at timestamp t contributes to the minute floor(t/60); if an interval ends exactly at t, it does NOT contribute to that minute; zero-length intervals contribute nothing; (4) Return the 95th percentile (nearest-rank) of the 1440 per-minute concurrency counts; (5) Target time complexity O(n log n + M) where M=1440, and sublinear extra memory beyond storing the sweep-line events; (6) Describe your data structures (e.g., external sort + sweep or streaming bucketing), tie-breaking, and how you would extend it to compute the same metric per country if each interval carries a country code. Provide clear pseudocode and justify correctness.

Quick Answer: This question evaluates a candidate's ability to design scalable algorithms for computing the 95th-percentile of per-minute concurrent calls over a 24-hour window, testing competencies in streaming/event aggregation, de-duplication, percentile computation, and managing time and memory constraints.

Related Interview Questions

  • Solve Tree Columns And Maze Variants - Meta (medium)
  • Solve Tree Diameter and Palindromic Counts - Meta (medium)
  • Simulate Monster Team Battles - Meta (hard)
  • Solve a Key-Door Corridor Maze - Meta (medium)
  • Solve Array Merge and Parentheses Cleanup - Meta (medium)
Meta logo
Meta
Oct 13, 2025, 9:49 PM
Data Scientist
Onsite
Coding & Algorithms
2
0

Given N call sessions as half-open intervals [start, end) in UNIX seconds, design an algorithm to compute the 95th percentile of per-minute concurrent calls over the last 24 hours ending at 2025-09-01 00:00:00 UTC (i.e., minutes from 2025-08-31 00:00 to 2025-09-01 00:00). Requirements: (1) Input is an unsorted stream that may not fit in memory; (2) The same call_id may appear multiple times; treat duplicate intervals as one after de-duplication by (start,end); (3) A call active at timestamp t contributes to the minute floor(t/60); if an interval ends exactly at t, it does NOT contribute to that minute; zero-length intervals contribute nothing; (4) Return the 95th percentile (nearest-rank) of the 1440 per-minute concurrency counts; (5) Target time complexity O(n log n + M) where M=1440, and sublinear extra memory beyond storing the sweep-line events; (6) Describe your data structures (e.g., external sort + sweep or streaming bucketing), tie-breaking, and how you would extend it to compute the same metric per country if each interval carries a country code. Provide clear pseudocode and justify correctness.

Submit Your Answer

Sign in to leave a comment

Loading comments...

Browse More Questions

More Coding & Algorithms•More Meta•More Data Scientist•Meta Data Scientist•Meta Coding & Algorithms•Data Scientist Coding & Algorithms
PracHub

Master your tech interviews with 8,500+ real questions from top companies.

Product

  • Questions
  • Learning Tracks
  • Interview Guides
  • Resources
  • Premium
  • For Universities
  • Student Access

Browse

  • By Company
  • By Role
  • By Category
  • Topic Hubs
  • SQL Questions
  • Compare Platforms
  • Discord Community

Support

  • support@prachub.com
  • (916) 541-4762

Legal

  • Privacy Policy
  • Terms of Service
  • About Us

© 2026 PracHub. All rights reserved.