We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent d279fcc commit e6b79c7Copy full SHA for e6b79c7
C++/video-stitching.cpp
@@ -4,8 +4,8 @@
4
class Solution {
5
public:
6
int videoStitching(vector<vector<int>>& clips, int T) {
7
- int result = 0;
8
- int curr_reachable = -1, reachable = 0;
+ int result = 1;
+ int curr_reachable = 0, reachable = 0;
9
sort(clips.begin(), clips.end());
10
for (const auto& clip : clips) {
11
int left = clip[0], right = clip[1];
0 commit comments