We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 89f0d89 commit 1aa5cfaCopy full SHA for 1aa5cfa
LeetcodeProblems/Algorithms/GasStation/index.js
@@ -34,7 +34,7 @@ var canCompleteCircuit = function(gas, cost) {
34
return -1;
35
else {
36
gasSum = costSum = 0;
37
- for (var i = 0; i < len; ++i) {
+ for (i = 0; i < len; ++i) {
38
gasSum += gas[i];
39
costSum += cost[i];
40
if (costSum > gasSum) {
0 commit comments