Skip to content

Commit f224513

Browse files
author
Gonzalo Diaz
committed
[BUGFIX] SonarQube: arrow function is equivalent to BigInt. Use BigInt directly.
Wrapper functions around built-in type conversion functions should be avoided javascript:S7770
1 parent a2341ae commit f224513

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/hackerrank/implementation/countApplesAndOranges.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,7 @@ function countApplesAndOranges(s, t, a, b, apples, oranges) {
1818
}
1919
}
2020

21-
const result = [];
22-
result.push(cApples);
23-
result.push(cOranges);
21+
const result = [...cApples, ...cOranges];
2422

2523
return result.join('\n');
2624
}

0 commit comments

Comments
 (0)