Skip to content

Conversation

axross
Copy link
Owner

@axross axross commented Oct 12, 2019

No description provided.

@axross axross self-assigned this Oct 12, 2019

for (let i = 0; i < nums.length - 2; ++i) {
if (nums[i] > 0) break;
if (nums[i] === nums[i - 1]) continue;
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Codacy has a fix for the issue: Expected { after 'if' condition.

Suggested change
if (nums[i] === nums[i - 1]) continue;
if (nums[i] === nums[i - 1]) {continue;}

nums.sort((a, b) => a - b);

for (let i = 0; i < nums.length - 2; ++i) {
if (nums[i] > 0) break;
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Codacy has a fix for the issue: Expected { after 'if' condition.

Suggested change
if (nums[i] > 0) break;
if (nums[i] > 0) {break;}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant