FastPrepSatellite Network Message Propagation
Problems/Satellite Network Message Propagation

Satellite Network Message Propagation

Optiver logoOptiver● HardFULLTIMEOA

Updated Nov 2026

QuestionFunctionExamplesConstraints

Problem statement

Source note: Reported in an Optiver online assessment. The network events, how forwarding runs at the same time, the timing, the error callbacks, and the examples match the report at about 98%. We chose to give you a fixed array of instructions, and a fixed order when several are invalid.

Maintain an undirected satellite network and simulate message propagation.

  • SATELLITE id connects a new satellite. If the ID already exists, output ErrDuplicateSatellite: id.
  • RELATION a b adds a two-way connection.
  • MESSAGE m id1 ... idm simultaneously notifies the listed satellites and runs one complete propagation.

An instruction that references nonexistent satellites outputs ErrInvalidSatellite: id once for every distinct invalid ID in left-to-right order, then makes no state change.

Propagation timing

  • Each notified satellite considers direct neighbors in increasing ID order.
  • It skips neighbors already known to be notified. It never tries to notify the satellite that notified it.
  • One forwarding attempt takes exactly 10 seconds, and one sender can have only one attempt in flight.
  • Two senders may attempt the same target concurrently. Even if another attempt finishes first or at the same time, each in-flight sender still spends its full 10 seconds.
  • After a sender finishes all required attempts, it spends 30 seconds processing and reports back.
  • Reports are ordered by time, then by smaller satellite ID.

Return every callback string in invocation order.

Function

simulateSatelliteNetwork(instructions: String[]) → String[]

Examples

Example 1

instructions = ["SATELLITE 1","SATELLITE 2","SATELLITE 3","RELATION 2 1","MESSAGE 1 2"]return = ["SatelliteReportedBack: 1","SatelliteReportedBack: 2"]

Satellite 2 forwards to 1 for 10 seconds. Both finish processing at time 40, so ID 1 reports first.

Example 2

instructions = ["SATELLITE 1","SATELLITE 2","SATELLITE 3","SATELLITE 4","SATELLITE 5","RELATION 1 3","RELATION 1 2","RELATION 2 5","RELATION 3 2","RELATION 3 4","RELATION 3 5","MESSAGE 2 1 3"]return = ["SatelliteReportedBack: 1","SatelliteReportedBack: 2","SatelliteReportedBack: 3","SatelliteReportedBack: 4","SatelliteReportedBack: 5"]

Satellites 1 and 3 start together. Concurrent attempts to 2 finish at time 10; all reports at time 50 are ordered by ID.

Constraints

  • 0 <= satelliteId < 2^16
  • 1 <= instructions.length <= 10^5
  • Each instruction has the documented valid token format.
  • Repeated relationships and duplicate IDs within one MESSAGE instruction are idempotent.

More Optiver Online Assessment questions

  • Power Cell BankOA · Seen Nov 2026
  • Overheat Prevention ControllerOA · Seen Nov 2026
  • Count Straight-Line Word Occurrences in a GridOA · Seen Sep 2026
  • Fastest Average Speed over a Rolling KilometerOA · Seen Sep 2026
  • Multi-Level Inventory Storage SystemOA · PHONE SCREEN · Seen Aug 2026
  • Proportional Momentum Investment StatisticsOA · Seen Aug 2026
  • Count Bounded Share TransactionsOA · Seen Aug 2026
  • Count Ordered Size SequencesOA · Seen Aug 2026
  • Profitable Currency Exchange CycleOA · Seen Aug 2026
  • Construct Binary Tree S-ExpressionOA · Seen Jul 2026

Similar questions at other companies

  • Concurrent Web Crawler SimulationOpenAI · PHONE SCREEN · ONSITE INTERVIEWOpenAI interview questions
  • Minimize Malware Spread by Removing a NodeVisa · OAVisa interview questions
  • Minimize Malware Spread by Removing a NodeAkuna Capital · OAAkuna Capital interview questions
  • Maximum Safeness of a Grid PathIntuit · OAIntuit interview questions
  • Course Schedule IIChainalysis · OAChainalysis interview questions
  • Reaching Points with Perfect-Square ObstaclesIMC Trading · OAIMC Trading interview questions
  • Fuel Route with Fewest Station VisitsGoogle · ONSITE INTERVIEWGoogle interview questions
  • Dynamic Broadcast TimesNetflix · PHONE SCREENNetflix interview questions
  • Shortest Path Around Moving ParadesZip · PHONE SCREENZip interview questions
  • Course Schedule IIAmazon · PHONE SCREEN · ONSITE INTERVIEW

Optiver interview experiences

  • Optiver SWE Intern OA: CPU Temperature Simulation: 1 Experience
  • Optiver Trading Intern Market-Making Games: 1 Experience
  • Optiver Quant Trader Intern Technical Interview: 1 Experience
  • Optiver SWE Intern System Design Interview: 15 Experiences
All Optiver interview questionsSee Optiver hiring insights
Saved
class Solution {
    public String[] simulateSatelliteNetwork(String[] instructions) {
      // write your code here
    }
}
Checking account…