First problem is this: https://leetcode.com/problems/nested-list-weight-sum/
Second problem:
Suppose you have a group of packages we want to ship. You are given a sorted array weights where weights[i] represents the weight of the ith package, and you are also given k which is the maximum number of days you have to deliver these packages.
You must choose a ship to ship these packages. Ships vary by their daily carrying capacity (how much weight they can carry on a one day trip). The same ship can deliver the packages over several days (for example, deliver first two packages on first day, then second package on second day, then last package on third day). You must choose the ship with the lowest capacity that can deliver all the packages in under the limit specified. Return the ship's capacity.
For example, weights may be [1,1,2,3] and K = 3. The answer would be 3, as we would ship 1,1 on first day, 2 on second day, and 2 on the third.