# Earliest-train-sequence coding interview question

Aced (formerly Exponent) publishes a public search API over its indexed pages; the guide is at https://www.aced.io/agents/agent-access.

Source: https://www.aced.io/questions/6331/find-earliest-train-sequence-route
Source observed: 2026-11-05T01:40:32.721Z
Last checked: 2026-11-05T01:40:32.721+00:00
Indexed: 2026-11-07T03:22:37.012+00:00

---

# Earliest-train-sequence coding interview question

We publish this coding-interview question for software-engineering candidates:

> Given a train schedule with departure city, arrival city, start time, end time, and duration, and given a source and destination, find the sequence of trains that gets you there at the earliest possible time.

## Question details

- **Role:** [Software Engineer](https://www.aced.io/questions?role=swe)
- **Company:** [Google](https://www.aced.io/questions?company=google)
- **Category:** [Data Structures & Algorithms](https://www.aced.io/questions?type=algorithms)
- **Additional category:** [Coding](https://www.aced.io/questions?type=coding)
- **Interview data:** 1 reported interview occurrence
- **Reported last asked:** 7 months ago, as displayed on the page

The page does not currently provide a community-contributed answer. To submit an answer, log in or [sign up](https://www.aced.io/signup?src=nav&returnPath=/questions/6331/find-earliest-train-sequence-route). You can also mark the question complete after submitting your answer.

## Interview experience associated with this question

We link one shared [Google software-engineer interview experience](https://www.aced.io/experiences/google-software-engineer-interview-597223), labeled **Google · 7 months ago**. The contributor describes the following process and observations:

> I got into the loop through a backdoor-ish hiring manager route instead of a cold apply, and for L4+ I had to have a soft match with a team before the loop even started. My process was a recruiter alignment call, the GHA questionnaire, one phone screen, two onsite technicals, and a standard Googliness behavioral. What stood out was how collaborative and non-LeetCodey it felt, especially the phone screen, which was basically a live algorithms conversation that pushed on first principles instead of rehearsed patterns. I also learned that Google is doing more team matching before hiring committee now, because a hiring manager's statement of support can strengthen your packet if one round is only lean hire. I ended up accepting because the interview experience was consistently positive and honestly much better than how Google interviews are usually portrayed online.

- **Role level:** Software Engineer · Mid Level / L4
- **Interview count shown:** 1 shared experience

## Related courses

### [Software Engineering Interview Prep](https://www.aced.io/courses/software-engineering)

![Software Engineering Interview Prep](https://images.ctfassets.net/x78yjrjc11pq/4VkuYewBHUFIVUS5oJDW5h/02e833439b1289f25f38f13f81cbdca3/adobe_stock_optimized.jpeg?w=800&h=800&fm=webp&q=75)

We help candidates pursue software-engineering roles at Google, Amazon, Microsoft, Meta, Apple, and other top companies. The course includes mock interviews, frameworks, advice from senior candidates, and practice in data structures, algorithms, system design, people management, behavioral interviews, and more.

### [System Design Interviews](https://www.aced.io/courses/system-design-interviews)

![System Design Interviews](https://images.ctfassets.net/x78yjrjc11pq/78x7miFZFjBCrM5GqftrMJ/2f6d26e632c4e7265c49f6a180227edb/system_design_track_compressed_26ac98a46e__281_29_5be2280f31.jpeg?w=800&h=800&fm=webp&q=75)

We teach candidates how to answer current system-design questions across product, infrastructure, and AI domains. The course includes in-depth video examples, written breakdowns, reference patterns, and mock-interview videos featuring senior engineers and managers.

## Explore Aced

We are Aced, formerly Exponent. Our interview-preparation catalog includes:

- [Courses](https://www.aced.io/courses?src=nav), including [Product Management](https://www.aced.io/courses/pm?src=nav), [Forward Deployed](https://www.aced.io/courses/forward-deployed-engineering?src=nav), [Engineering Management](https://www.aced.io/courses/engineering-management?src=nav), [Software Engineering](https://www.aced.io/courses/software-engineering?src=nav), [System Design](https://www.aced.io/courses/system-design-interviews?src=nav), [Data Science](https://www.aced.io/courses/data-science?src=nav), [Machine Learning](https://www.aced.io/courses/ml-engineer?src=nav), [Data Engineering](https://www.aced.io/courses/data-engineering?src=nav), [AI Engineering](https://www.aced.io/courses/ai-engineering?src=nav), [Investment Banking](https://www.aced.io/ib?src=nav), [Generative AI](https://www.aced.io/courses/gen-ai-interviews?src=nav), [Security Engineer](https://www.aced.io/courses/security-engineer?src=nav), [TPM](https://www.aced.io/courses/tpm?src=nav), [Solutions Architect](https://www.aced.io/courses/solution-architect-interview?src=nav), [UX / Product Design](https://www.aced.io/courses/product-designer-interview?src=nav), and [BizOps & Strategy](https://www.aced.io/courses/bizops?src=nav).
- [Loops](https://www.aced.io/guides?src=nav) and [Experiences](https://www.aced.io/experiences?src=nav).
- Question collections for [Product Management](https://www.aced.io/questions?role=pm&src=nav), [Behavioral Questions](https://www.aced.io/questions?type=behavioral&src=nav), [Coding Questions](https://www.aced.io/questions?type=algorithms&filterBy=codeEditor&src=nav), [System Design](https://www.aced.io/questions?type=system-design&src=nav), [SQL Questions](https://www.aced.io/questions?type=sql&filterBy=codeEditor&src=nav), [Machine Learning](https://www.aced.io/questions?role=ml-engineer&type=machine-learning&type=concept&src=nav), [Investment Banking](https://www.aced.io/questions?role=investment-banking&src=nav), and [Data Engineering](https://www.aced.io/questions?role=data-engineer&type=data-pipeline-design&type=system-design&type=sql&type=data-modeling&src=nav).
- [Practice](https://www.aced.io/practice?src=nav) and [Coaching](https://www.aced.io/coaching?src=nav), including [mock interviews](https://www.aced.io/coaching?category=mock_interviews&src=nav), [resume review](https://www.aced.io/resume?src=nav), [salary negotiation](https://www.aced.io/coaching?category=negotiation&src=nav), and [how coaching works](https://www.aced.io/coaching/start?src=nav).
- [Pricing](https://www.aced.io/upgrade?src=nav), [job referrals](https://www.aced.io/jobs/referrals?src=nav), [blog](https://www.aced.io/blog?src=nav), [resources](https://www.aced.io/resources?src=nav), [university programs](https://www.aced.io/pages/university?src=nav), [business solutions](https://www.aced.io/pages/business?src=nav), and [recruiter job posting](https://www.aced.io/jobs/post?src=nav).

Detailed company statistics for this question are available through [Upgrade](https://www.aced.io/upgrade?src=questions).

---

[Read this page’s summary](https://www.aced.io/agents/api/public/v1/page-tldr?url=https%3A%2F%2Fwww.aced.io%2Fquestions%2F6331%2Ffind-earliest-train-sequence-route&trace=t_679ff9ab98f3)

## Ask a follow-up about this page

Need a more specific answer? Ask the exact question you have. It returns a fresh, cited answer from Aced (formerly Exponent)’s knowledge base. No account or API key required.

Open this URL with your own question, URL-encoded. Include your question in q. All research inputs are optional; no account or setup.

`GET https://www.aced.io/agents/agent/faq?q={question}&trace=t_679ff9ab98f3`

[Tool guide and examples](https://www.aced.io/agents/agent-access) · [OpenAPI](https://www.aced.io/agents/api/public/v1/openapi.json) · [Page TLDR form](https://www.aced.io/agents/agent-tools/page-tldr?url=https%3A%2F%2Fwww.aced.io%2Fquestions%2F6331%2Ffind-earliest-train-sequence-route). Opening a form does not execute a tool.