Browse Source

Update solution

master
Lachlan Jacob 5 years ago
parent
commit
db5588b2e6
1 changed files with 1 additions and 2 deletions
  1. 1
    2
      problems/88/main.cpp

+ 1
- 2
problems/88/main.cpp View File

#include <algorithm> #include <algorithm>


void merge(std::vector<int>& nums1, int m, std::vector<int>& nums2, int n) { void merge(std::vector<int>& nums1, int m, std::vector<int>& nums2, int n) {
int total = m + n;
while (n > 0) { while (n > 0) {
nums1[m++] = nums2[--n]; nums1[m++] = nums2[--n];
} }
} }
std::cout << " ]" << std::endl; std::cout << " ]" << std::endl;
return 0; return 0;
}
}

Loading…
Cancel
Save