Opening your workspace…
Workspace/Coding room
Opening your workspace…
The brewery parcels are queued by birthday. Reordering them once caused a pudding to turn eighty on the platform. Load the queue, in order, onto the available sledges (given by the integer sleds). Each sledge takes one consecutive block. Return the smallest weight limit per sledge that gets every parcel aboard. Practice rank · 4 kyu (Brewery estimate).
[5,1,4,3], 2OUTPUT7Loads of six and seven fit. A limit of six strands the last parcel.
[9], 1OUTPUT9The birthday cake travels alone.
Given a proposed limit, count sledges by filling each as far as it will go. Which smaller limits can you rule out?
function solve(weights, sleds) { // Write your answer here. }
Tab inserts two spaces. Shift+Tab outdents. Use the arrow keys and Tab to choose a suggestion. Press Escape, then Tab, to leave the editor. Press Control or Command with apostrophe to run samples or with Enter to submit.
[5,1,4,3], 27