PracHub
QuestionsPremiumLearningGuidesCheatsheetNEWCoaches
|Home/Coding & Algorithms/BlackRock

Implement sorting and set intersection with input parsing

Last updated: Mar 29, 2026

Quick Overview

This question evaluates proficiency in algorithm design and implementation, specifically sorting algorithms, set intersection logic, input parsing, and analysis of time/space complexity and algorithm stability within the Coding & Algorithms domain.

  • Medium
  • BlackRock
  • Coding & Algorithms
  • Software Engineer

Implement sorting and set intersection with input parsing

Company: BlackRock

Role: Software Engineer

Category: Coding & Algorithms

Difficulty: Medium

Interview Round: Take-home Project

Write two functions and explain your approach in under two minutes after coding: (A) Sorting: Implement sort_numbers(nums: List[int]) -> List[int] that returns nums in non-decreasing order without using built-in sort; use a standard algorithm and describe time/space complexity and stability. (B) Set Intersection: Implement intersect_sets(a: Iterable[int], b: Iterable[int]) -> List[int] that returns the unique elements present in both a and b in ascending order; describe time/space complexity and key edge cases (e.g., empty inputs, duplicates). Assume you must handle input parsing yourself (no helpers), and you will have two fixed test cases with a single allowed submission.

Quick Answer: This question evaluates proficiency in algorithm design and implementation, specifically sorting algorithms, set intersection logic, input parsing, and analysis of time/space complexity and algorithm stability within the Coding & Algorithms domain.

Related Interview Questions

  • Solve two interval array problems - BlackRock (medium)
  • Traverse a tree and answer 2D prefix sums - BlackRock (easy)
  • Design paint editor with undo/redo - BlackRock (easy)
  • Solve hierarchy distance and digit-square convergence - BlackRock (Medium)
BlackRock logo
BlackRock
Sep 6, 2025, 12:00 AM
Software Engineer
Take-home Project
Coding & Algorithms
3
0

Write two functions and explain your approach in under two minutes after coding: (A) Sorting: Implement sort_numbers(nums: List[int]) -> List[int] that returns nums in non-decreasing order without using built-in sort; use a standard algorithm and describe time/space complexity and stability. (B) Set Intersection: Implement intersect_sets(a: Iterable[int], b: Iterable[int]) -> List[int] that returns the unique elements present in both a and b in ascending order; describe time/space complexity and key edge cases (e.g., empty inputs, duplicates). Assume you must handle input parsing yourself (no helpers), and you will have two fixed test cases with a single allowed submission.

Comments (0)

Sign in to leave a comment

Loading comments...

Browse More Questions

More Coding & Algorithms•More BlackRock•More Software Engineer•BlackRock Software Engineer•BlackRock Coding & Algorithms•Software Engineer Coding & Algorithms
PracHub

Master your tech interviews with 7,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.