Sanjaay Gowda T S
All company profiles

COMPANY CONTEXT / 94 IN THE STUDY LIST

CNOOC Limited

EnergyHong KongData scienceSoftware engineering

CNOOC Limited operates oil and gas exploration and production businesses.

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

Data science

Summarize irregular sensor readings

CNOOC Limited · Concept

Original practice scenario inspired by CNOOC Limited's public business context; this is not a reported interview question or a description of its internal systems. A fictional offshore operations dataset records a measurement whenever its value changes, with periodic heartbeats. Explain why an ordinary average may mislead and how to estimate a time-weighted daily mean.

Read model answer

Event-triggered samples overrepresent periods when values change frequently. A time-weighted mean asks how long each value represented the process, subject to a defensible interpolation and staleness rule.

Work through it

  1. Sort and deduplicate sensor events, normalize timestamps, and define whether values remain constant until the next reading or require another interpolation method.
  2. Intersect each valid interval with the reporting day, multiply value by covered duration, and divide by total valid covered time. Split intervals at day boundaries.
  3. Publish coverage and exclude intervals beyond the allowed heartbeat gap. Test midnight crossings, duplicate timestamps, missing days, and a long stale period.

Tradeoffs to discuss

  • A step-function estimate is transparent but may be wrong for rapidly varying processes. More sophisticated interpolation needs domain evidence and still cannot recover unobserved events exactly.

Common pitfalls

  • A simple row average depends on sampling behavior.
  • Filling an entire outage with the last value can create a precise-looking daily mean from almost no valid coverage.
Open full question
Original company-context practiceHard

Software engineering

Recover an offline field-data buffer

CNOOC Limited · Concept

Original practice scenario inspired by CNOOC Limited's public business context; this is not a reported interview question or a description of its internal systems. A synthetic field device buffers observations on disk while connectivity is unavailable. It can lose power during a write or acknowledgement. Explain a durable queue and replay protocol that avoids silent gaps.

Read model answer

Use a crash-consistent local log with stable record identities and explicit acknowledgement checkpoints. Connectivity retries should resend the same observation, allowing the receiver to deduplicate rather than relying on exactly-once transport.

Work through it

  1. Frame records with lengths and checksums, and define when a write is durably committed. On recovery, detect and truncate or quarantine an incomplete trailing record.
  2. Upload bounded batches with stable IDs. Advance the local acknowledgement checkpoint only after durable remote acceptance, then reclaim acknowledged storage safely.
  3. Test power loss at each write and checkpoint boundary, repeated acknowledgements, disk exhaustion, and a prolonged outage. Expose dropped or rejected records through counters.

Tradeoffs to discuss

  • Stronger durability increases write latency and storage wear. Capacity limits need an explicit retention or backpressure policy rather than an unbounded promise.

Common pitfalls

  • Deleting a batch when sending starts loses data on timeout.
  • Reusing sequence IDs after a device reset can cause valid observations to be mistaken for duplicates.
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