Skip to content

Commit

Permalink
Update move-zeroes.cpp
Browse files Browse the repository at this point in the history
  • Loading branch information
kamyu104 committed Jun 6, 2016
1 parent 84f22f1 commit e575c33
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion C++/move-zeroes.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ class Solution {
public:
void moveZeroes(vector<int>& nums) {
int pos = 0;
for (const auto& num : nums) {
for (auto& num : nums) {
if (num) {
swap(nums[pos++], num);
}
Expand Down

0 comments on commit e575c33

Please sign in to comment.