Interview guides · Cubic
Cubic Software Engineer Interview Guide
Cubic Software Engineer interview guide: reported rounds, questions and how candidates describe the process.
The 60-second brief
As a Software Engineer at Cubic, you are at the intersection of complex systems, mission-critical infrastructure, and innovative technology. You will contribute to the development of sophisticated solutions that power transportation, defense, and public sector systems. Your work directly impacts how millions of people move through cities and how government agencies maintain operational awareness. This role is not merely about writing code; it is about engineering reliability and scalability in environments where precision is paramount. Whether you are working on embedded systems, high-availability database architecture, or real-time transit platforms, you will be expected to solve multifaceted problems that require deep technical rigor and an understanding of the broader system lifecycle.
This guide is scoped to a Software Engineer candidate at Cubic.
Focus areas
- Data modeling & SQL
- Embedded systems programming
- Resume communication / resume crafting
The Cubic interview process
Cubic candidates report 3 rounds over 3-5 weeks. The stages below are what candidates describe, not a published process.
Recruiter Screening
Initial assessment of your experience and fit for the role.
What to demonstrate
- Initial assessment of your experience and fit for the role
- Depth in Data modeling & SQL
How to prepare
- Be able to walk your CV end to end in two minutes, and say why this company specifically.
- Have your salary expectations, notice period and location constraints ready, and ask for the rest of the loop in writing.
Technical Assessments
Granular evaluations of your technical skills and competencies.
What to demonstrate
- Granular evaluations of your technical skills and competencies
- Depth in Data modeling & SQL
How to prepare
- Answer aloud and timed: What are the primary considerations when working with embedded C++ in resource-constrained environments?
- Answer aloud and timed: Describe your experience with SQL performance optimization and indexing strategies.
Final Panel Interviews
Interviews with stakeholders to assess overall fit and collaboration skills.
What to demonstrate
- Interviews with stakeholders to assess overall fit and collaboration skills
- Depth in Data modeling & SQL
How to prepare
- Answer aloud and timed: How do you handle concurrency in a multi-threaded application?
- Answer aloud and timed: Tell me about a time you had to resolve a technical disagreement within your team.
Where candidates lose points
Own your resume
Be prepared to speak in detail about every project you list. If you mention a technology, be prepared to answer technical questions about its implementation.
Ask meaningful questions
Use the time at the end of your interviews to ask about the team’s current technical challenges or the product roadmap. This shows genuine interest in our mission.
Practice whiteboarding
Even in remote settings, you may be asked to explain your logic on a virtual whiteboard or text editor. Practice articulating your thought process as you solve problems.
Be honest about your experience
If you are unfamiliar with a specific tool, acknowledge it, but explain how you would go about learning or finding a solution. We value honesty and a "growth mindset" over feigned expertise.
Questions & practice
How do you handle concurrency in a multi-threaded application?
Medium · Technical & Domain Knowledge
Approach
- Say what the runtime actually does before reasoning about the code.
- Name what is shared across threads and what owns each piece of state.
- Identify the window where an invariant is briefly untrue.
- Distinguish a value from a reference to it, and say which one you handed out.
Follow-up
- What happens if two callers reach this at the same time?
- Where could this allocate more than you expect?
Walk me through your approach to solving an algorithmic problem, such as finding a specific element in an arra
Medium · Problem-Solving & Design
Walk me through your approach to solving an algorithmic problem, such as finding a specific element in an array.
Approach
- Restate the input: its shape, its size, and what is guaranteed about it.
- Name the brute-force solution and its complexity before improving on it.
- Choose the data structure from the access pattern, not from familiarity.
- State the target complexity and say which constraint rules the naive version out.
Follow-up
- How does this change if the input no longer fits in memory?
- What is the worst case, and how likely is it on real data?
Collapse a redelivered event batch into per-aggregate high-water marks
Easy · hashing · at-least-once · aggregation
You drain a batch of up to 5,000,000 events, each (aggregate_id BIGINT, aggregate_version INT, event_type, payload). The log guarantees order within one aggregate only; the batch merges 64 partitions, and a relay failover has redelivered a range, so an older version for an aggregate can appear after a newer one. Given a map of last_applied_version per aggregate, produce the events worth applying, at most one per (aggregate_id, version), plus the count discarded. Target O(n) time. State the memory for 2,000,000 distinct aggregates and what you do when it does not fit.
Approach
- One pass, one hash map from aggregate_id to the highest version kept, and a discard counter. An event whose version is at or below last_applied_version for its aggregate is dropped without further work, which is the whole reason the event carries its version rather than a delta. O(n) expected time, O(d) space in distinct aggregates.
- Keep the maximum, never the last occurrence. The redelivered range means the final appearance of an aggregate in the batch can be an older version than one seen earlier in the same batch, so last-wins applies stale state over newer state and the projection regresses with no error anywhere.
- Cost the memory instead of calling it large: an 8-byte key plus a 4-byte version is 12 bytes of payload, and an open-addressed table held at a 0.7 load factor costs roughly 17 bytes per entry before per-slot metadata, so 2,000,000 aggregates is tens of megabytes in a native layout and several times that in a runtime that boxes both key and value.
- If the distinct set exceeds memory, partition on hash(aggregate_id) mod P and reduce each partition independently. Every event for one aggregate hashes to the same partition, so the per-partition result is exact and the merge is concatenation rather than a second reduction.
Follow-up
- The payload is a patch rather than a snapshot, so applying only the highest version loses the intermediate changes. What changes in your reduction?
- How do you detect that version 7 arrived while version 6 was never delivered, and what should the consumer do about the gap?
Explain why the owner filter ignores the listing index
Medium · composite index · query plans · sort elimination
The only index on resource is (tenant_id, status, updated_at DESC, resource_id DESC). A new endpoint returns one user's resources across all statuses, newest created first: WHERE tenant_id = $1 AND owner_user_id = $2 ORDER BY created_at DESC LIMIT 20. On a tenant with 2M rows it takes 900 ms and EXPLAIN shows a sort above a large scan. Explain precisely why the existing index cannot serve it, give the index that can, and state which of these the new index still will not help: owner_user_id alone across tenants; the same query ordered by updated_at. PostgreSQL 16.
Approach
- Separate the two jobs an index does. For filtering, a composite btree is seekable only on a left prefix, so with no predicate on status the scan can at best range over tenant_id and test owner_user_id per row; PostgreSQL 16 has no btree skip scan to jump the unconstrained column.
- For ordering, the index is sorted by (status, updated_at) within a tenant and not by created_at, so the LIMIT cannot stop early: every matching row is read and then sorted. That is the 'Sort Method: top-N heapsort' line, and it is why the plan reads 2M rows to answer with 20.
- Derive the replacement from the access path — equality, equality, then the ordering column: CREATE INDEX CONCURRENTLY ON resource (tenant_id, owner_user_id, created_at DESC). The scan seeks to the (tenant, owner) range and walks 20 entries in order, so the Sort node disappears along with the row-read.
- Treat INCLUDE (title, status) as conditional, not free. An index-only scan still visits the heap for any row whose page is not marked all-visible, so on a table taking 1.2k writes/second the win depends on autovacuum keeping the visibility map current, and the wider index costs more on every insert.
Follow-up
- 90% of rows are status='active'. Would a partial index WHERE status = 'active' change your answer, and for which of the three queries?
- A dashboard runs this for 40 owners in one page load. What changes about the design?
Find version gaps and relay lag with window functions
Medium · window functions · event tables · frame semantics
outbox_event holds event_id, aggregate_type, aggregate_id, aggregate_version, event_type, payload, status ('pending','published','dead'), attempts, created_at, published_at. A projection is missing rows and you must decide whether the relay skipped events or the consumer dropped them. Write three queries over the last seven days: one listing every aggregate_id whose published aggregate_version sequence has a hole, one giving per-day counts with a running total, and one returning the newest published event per aggregate. For each, say where the window function is evaluated relative to WHERE and LIMIT. PostgreSQL 16.
Approach
- Gaps: compute lead(aggregate_version) OVER (PARTITION BY aggregate_id ORDER BY aggregate_version) in a subquery, then filter next_version <> aggregate_version + 1 in the outer query. Window functions are evaluated after WHERE, GROUP BY and HAVING and before the outer ORDER BY and LIMIT, so the predicate cannot sit in the same WHERE clause and PostgreSQL 16 has no QUALIFY.
- Say what the seven-day filter does to the answer: it truncates every partition, so the first row per aggregate has no predecessor inside the window and a hole spanning the boundary is invisible. Widen the window, or join to resource.version as the authority for the true maximum.
- Running total: SELECT date_trunc('day', created_at) AS d, count() AS n, sum(count()) OVER (ORDER BY date_trunc('day', created_at) ROWS UNBOUNDED PRECEDING). An aggregate inside a window call is legal because grouping runs before windowing. The grouping key is unique per row here so ROWS and RANGE agree, but write the frame anyway — over ungrouped rows with tied timestamps the default RANGE frame pulls in every peer row and the total jumps.
- Newest per aggregate: DISTINCT ON (aggregate_id) ... ORDER BY aggregate_id, aggregate_version DESC is the cheap PostgreSQL-only form when an index matches that order; row_number() OVER (PARTITION BY aggregate_id ORDER BY aggregate_version DESC) = 1 is the portable form and needs a subquery for the same evaluation-order reason as the gap query.
Follow-up
- Relay failover redelivers events. Does a duplicate break the gap query, and how would you detect one from this table alone?
- Turn the gap check into a continuous monitor rather than a query someone runs after an incident. What does it watch?
How would you design a schema for a high-traffic transit ticketing system?
Medium · Technical & Domain Knowledge
Approach
- Fix the scope first: who calls this, how often, and what they do when it fails.
- Name the read and write paths separately; they rarely have the same bottleneck.
- Choose a partition key and say what query it makes expensive.
- State the consistency you need, and where you are willing to be stale.
Follow-up
- What breaks first when traffic grows ten times?
- How does this behave when that dependency is down for an hour?
Can you explain the difference between RESTful APIs and SOAP in terms of scalability?
Medium · Technical & Domain Knowledge
Approach
- Fix the scope first: who calls this, how often, and what they do when it fails.
- Name the read and write paths separately; they rarely have the same bottleneck.
- Choose a partition key and say what query it makes expensive.
- State the consistency you need, and where you are willing to be stale.
Follow-up
- What breaks first when traffic grows ten times?
- How does this behave when that dependency is down for an hour?
What are the primary considerations when working with embedded C++ in resource-constrained environments?
Medium · Technical & Domain Knowledge
Approach
- Clarify what is being asked and what a complete answer contains.
- State your assumptions explicitly before working the problem.
- Say what you would check first and why it is the highest-information step.
- Work from the requirement backwards to the design.
Follow-up
- What assumption would you test first?
- How would you know your answer was wrong?
How would you architect a service that needs to process real-time data streams?
Medium · Problem-Solving & Design
Approach
- Fix the scope first: who calls this, how often, and what they do when it fails.
- Name the read and write paths separately; they rarely have the same bottleneck.
- Choose a partition key and say what query it makes expensive.
- State the consistency you need, and where you are willing to be stale.
Follow-up
- What breaks first when traffic grows ten times?
- How does this behave when that dependency is down for an hour?
How do you ensure your code remains maintainable and scalable as project requirements change?
Medium · Problem-Solving & Design
Approach
- Fix the scope first: who calls this, how often, and what they do when it fails.
- Name the read and write paths separately; they rarely have the same bottleneck.
- Choose a partition key and say what query it makes expensive.
- State the consistency you need, and where you are willing to be stale.
Follow-up
- What breaks first when traffic grows ten times?
- How does this behave when that dependency is down for an hour?
How do you approach debugging a critical production failure under pressure?
Medium · Behavioral & Situational
Approach
- Establish what changed and when, before forming any theory.
- Pick a bisection that eliminates candidates whichever way it turns out.
- Check the instrumentation before believing the symptom.
- Separate the trigger from the cause; the deploy is rarely the bug.
Follow-up
- What would you look at first, and what would it rule out?
- How would you tell a cause from a coincidence here?
Suggested practice checklist
Built from the rounds and topics Cubic candidates report.
Day 1 — Map the Cubic loop
- Write out the reported sequence: Recruiter Screening, Technical Assessments, Final Panel Interviews.
- For each round, write one sentence on what it is judging, from the description above, and mark the one you are least ready for.
Deliverable: A one-page map of the 3 reported rounds, with the weakest marked.
Day 2 — Work Data modeling & SQL
- Spend the session on Data modeling & SQL, which Cubic candidates report being tested on.
- Write one worked example in Data modeling & SQL and time yourself on it.
Deliverable: One timed worked example in Data modeling & SQL.
Day 3 — Work Embedded systems programming
- Spend the session on Embedded systems programming, which Cubic candidates report being tested on.
- Write one worked example in Embedded systems programming and time yourself on it.
Deliverable: One timed worked example in Embedded systems programming.
Day 4 — Work Resume communication / resume crafting
- Spend the session on Resume communication / resume crafting, which Cubic candidates report being tested on.
- Write one worked example in Resume communication / resume crafting and time yourself on it.
Deliverable: One timed worked example in Resume communication / resume crafting.
Day 5 — Answer out loud: Technical & Domain Knowledge
- Answer aloud, timed: How would you design a schema for a high-traffic transit ticketing system?
- Answer aloud, timed: Can you explain the difference between RESTful APIs and SOAP in terms of scalability?
Deliverable: Spoken answers to 2 reported Technical & Domain Knowledge question(s), under time.
Day 6 — Answer out loud: Behavioral & Situational
- Answer aloud, timed: Tell me about a time you had to resolve a technical disagreement within your team.
- Answer aloud, timed: How do you manage your time when balancing multiple project deadlines?
Deliverable: Spoken answers to 2 reported Behavioral & Situational question(s), under time.
Day 7 — Answer out loud: Problem-Solving & Design
- Answer aloud, timed: How would you architect a service that needs to process real-time data streams?
- Answer aloud, timed: Walk me through your approach to solving an algorithmic problem, such as finding a specific element in an array.
Deliverable: Spoken answers to 2 reported Problem-Solving & Design question(s), under time.
Behavioural preparation
Behavioural rounds judge the decision you made and what it cost.
Describe your experience with SQL performance optimization and indexing strategies.
Medium · Technical & Domain Knowledge
Approach
- Pick a story where you made the decision, not one where you watched it.
- State the situation in two sentences and spend the rest on the reasoning.
- Give the blast radius: what could have broken, and what you measured.
- Name the disagreement and how you resolved it with evidence.
Follow-up
- What would you do differently if you ran that again?
- How did you know your change caused the improvement?
Tell me about a time you had to resolve a technical disagreement within your team.
Medium · Behavioral & Situational
Approach
- Pick a story where you made the decision, not one where you watched it.
- State the situation in two sentences and spend the rest on the reasoning.
- Give the blast radius: what could have broken, and what you measured.
- Name the disagreement and how you resolved it with evidence.
Follow-up
- What would you do differently if you ran that again?
- How did you know your change caused the improvement?
How do you manage your time when balancing multiple project deadlines?
Medium · Behavioral & Situational
Approach
- Pick a story where you made the decision, not one where you watched it.
- State the situation in two sentences and spend the rest on the reasoning.
- Give the blast radius: what could have broken, and what you measured.
- Name the disagreement and how you resolved it with evidence.
Follow-up
- What would you do differently if you ran that again?
- How did you know your change caused the improvement?
Describe a project where you had to learn a new technology stack on the fly.
Medium · Behavioral & Situational
Approach
- Pick a story where you made the decision, not one where you watched it.
- State the situation in two sentences and spend the rest on the reasoning.
- Give the blast radius: what could have broken, and what you measured.
- Name the disagreement and how you resolved it with evidence.
Follow-up
- What would you do differently if you ran that again?
- How did you know your change caused the improvement?