1101-1110

1101. The Earliest Moment When Everyone Become Friends $\star\star$

1102. Path With Maximum Minimum Value $\star\star$

1103. Distribute Candies to People $\star$

1104. Path In Zigzag Labelled Binary Tree $\star\star$

1105. Filling Bookcase Shelves $\star\star$

1106. Parsing A Boolean Expression $\star\star\star$

1107. New Users Daily Count $\star\star$

1108. Defanging an IP Address $\star$

1109. Corporate Flight Bookings $\star\star$

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
class Solution {
 public:
  vector<int> corpFlightBookings(vector<vector<int>>& bookings, int n) {
    vector<int> ans(n);

    for (vector<int>& booking : bookings) {
      ans[booking[0] - 1] += booking[2];
      if (booking[1] < n) ans[booking[1]] -= booking[2];
    }

    for (int i = 1; i < n; ++i) ans[i] += ans[i - 1];

    return ans;
  }
};

1110. Delete Nodes And Return Forest $\star\star$