GoGo byteAdvanced~3h time-box

Bundle Pricing

An online retailer sells five distinct product SKUs. Each item costs $8 at full price. To encourage bundle purchases, the retailer offers tiered discounts when a customer buys distinct items together:

Bundle Pricing
Step 1
Clone the starter repo
Candidate gets the full project locally — README, source, tests, runner config.
Step 2
Run the visible tests
Public test file is right there. Expectations are explicit from minute one.
Step 3
Make tests pass, push
Candidate works in their own style, pushes reviewable commits for your team.
Starter repo
What candidates clone
3 files
  • bundle_pricing.go
  • bundle_pricing_test.go
  • cases_test.go

The full README and the hidden test suite are available once you open the byte in your CodeSubmit workspace. Candidates never see the hidden tests.

Skills tested
algorithmsintegerslistsoptimization
Difficulty
Advanced

Non-trivial design choices. Tests multiple skills under time pressure.

Also available in
Keep exploring

More Go bytes

See all Go bytes