FastPrepBlock Type with the Most Children
Problems/Block Type with the Most Children

Block Type with the Most Children

Notion logoNotion● MediumFULLTIMEPHONE SCREEN

Updated Nov 2026

QuestionConstraints

Problem statement

Source note: A Notion data-engineering phone-screen report lists finding the block type with the most children. We chose the schema, that only direct children count, how counts add up across parents, and the tie rule.

Each block can be a root or a direct child of another block. Return the parent block type whose blocks collectively have the largest number of direct children.

Do not count root blocks as children. If several parent types tie, return the alphabetically smallest type. Return block_type and child_count.

Table schema

MySQLPostgreSQLPandas

Use the same input data with any supported language. Open the Schema tab in the editor to see the generated SQL setup or Pandas DataFrames.

blocks

ColumnTypeNullableDescription
block_idPKIntegerNo—
parent_block_idIntegerYes—
block_typeTextNo—

Foreign key: parent_block_id → blocks(block_id)

Expected result

Your query or function must return these columns.

ColumnTypeNullableDescription
block_typeTextNo—
child_countIntegerNo—

Row order: must match exactly. Numeric tolerance: 0.

Constraints

  • parent_block_id is null only for root blocks.
  • At least one child block is present.
  • Count only direct parent-child relationships.

More Notion interview questions

  • Nested Todo ListPHONE SCREEN · ONSITE INTERVIEW · Seen Sep 2026
  • Mutable Table AggregationsPHONE SCREEN · ONSITE INTERVIEW · Seen Apr 2026
  • Country with the Most EventsPHONE SCREEN · Seen Mar 2026
  • Event Type with the Most EventsPHONE SCREEN · Seen Mar 2026
  • Most Popular Active Plan for the Top Event TypePHONE SCREEN · Seen Mar 2026
  • Page Permission InheritancePHONE SCREEN · ONSITE INTERVIEW · Seen Mar 2026
  • Percentage of Blocks Never EditedPHONE SCREEN · Seen Mar 2026
  • Text Document HistoryPHONE SCREEN · ONSITE INTERVIEW · Seen Mar 2026
  • Versioned Document StorePHONE SCREEN · Seen Apr 2025
  • Top Error Types in a Time WindowONSITE INTERVIEW · Seen Jun 2026

Similar questions at other companies

  • Nth Highest SalaryPaytm · PHONE SCREENPaytm interview questions
  • Email Funnel: Opened Within a Day, Replied Within a WeekSuperhuman · PHONE SCREENSuperhuman interview questions
  • iPhone Model Sales Share by CountryApple · PHONE SCREENApple interview questions
  • Top Three Accounts by Monthly Transaction AmountMastercard · PHONE SCREENMastercard interview questions
  • In-Memory Database QueriesOpenAI · PHONE SCREEN · ONSITE INTERVIEWOpenAI interview questions
  • Top Three Sales per County and YearClickhouse · PHONE SCREEN
  • Third-Highest Known SalaryAdobe · PHONE SCREENAdobe interview questions
  • Days Between Each User's Latest Two PostsZip · PHONE SCREENZip interview questions
  • Observed-User Percentage by AppMicrosoft · PHONE SCREENMicrosoft interview questions
  • Nth-Highest Book Sales VolumeAmazon · PHONE SCREEN

Notion interview experiences

  • Notion Interviews, Level Not Reported: 20 Experiences
  • Notion Experienced SWE Interviews: 7 Experiences
  • Notion SWE New Grad Interviews: 3 Experiences
  • Notion SWE Intern Interviews and Debugging Round: 6 Experiences
  • Notion New Grad SWE Onsite Invitations: 2 Experiences
All Notion interview questionsSee Notion hiring insights