Sanjaay Gowda T S
All company profiles

COMPANY CONTEXT / 38 IN THE STUDY LIST

PetroChina Company Limited

EnergyChinaSoftware engineeringSQL & data engineering

PetroChina operates oil and gas businesses including production, refining and distribution.

Original company-context practice, not verified company interview questions. Use the business setting to explain technical choices clearly.

01 / PRACTICE IN CONTEXT

Two problems to reason through.

Clarify assumptions before reading the model answer. Discuss what would change with different constraints.

Original company-context practiceHard

Software engineering

Detect conflicting pipeline transfer windows

PetroChina Company Limited · Concept

Original practice scenario: A hypothetical logistics planner schedules transfers through shared pipeline segments. Transfers occupy multiple consecutive segments and require separation between incompatible products. Design conflict detection.

Read model answer

Define occupancy intervals and compatibility constraints explicitly. A transfer cannot be validated by checking only its start time or the first segment it uses.

Work through it

  1. Represent the planned route, segment-specific entry and exit times, product class and required separation, using a consistent boundary convention and time basis.
  2. Check interval overlap against existing reservations on every affected segment, applying additional separation rules where product transitions require them.
  3. Reserve the complete feasible route consistently, returning the conflicting segment and rule when a concurrent booking or later adjustment invalidates the plan.

Tradeoffs to discuss

  • Conservative buffers simplify conflict control but reduce throughput; tighter schedules require stronger timing evidence and recovery options.

Common pitfalls

  • An interval ending exactly when another begins is valid only under the chosen separation rule.
  • This scheduling exercise does not establish hydraulic feasibility or authorize real pipeline operation.
Open full question
Original company-context practiceHard

SQL & data engineering

Aggregate gas-quality readings using compatible weights

PetroChina Company Limited · Concept

Original practice scenario: A hypothetical energy report combines gas streams with different measured volumes and energy-content readings. Explain why a simple average can misstate the combined result.

Read model answer

Choose a consistent physical basis and weight each valid measurement by the associated flow over its supported interval. An unweighted mean gives a tiny stream the same influence as a large one.

Work through it

  1. Retain stream identity, measurement interval, flow unit, reference conditions and quality status, aligning intervals before combining observations.
  2. Convert compatible measures under an approved rule and compute weighted contributions from valid overlapping coverage, preserving unavailable readings as missing evidence.
  3. Report total supported flow and the combined measure with coverage, reconciling contributions to the original streams and separating intervals with insufficient quality data.

Tradeoffs to discuss

  • Time alignment improves interpretability but may require resampling assumptions; coarse aggregation uses fewer assumptions while hiding short-lived variation.

Common pitfalls

  • Do not mix volumes measured at incompatible reference conditions without an explicit conversion.
  • A missing quality reading cannot safely contribute a zero value to a weighted average.
Open full question

02 / STRENGTHEN THE FOUNDATIONS

Related technical practice.

Browse company questions

03 / TEST AN APPROACH

Suggested coding exercises.

Exercises selected for these technical tracks. They are independent practice with visible tests and public solutions.

Study list: PwC Global Top 100 companies by market capitalisation, 2026 · 31 March 2026.

Keep learning beyond the interview.

Explore the Learning Hub