Skip to content

Commit af750c0

Browse files
committed
refactored unnecessary spread
1 parent 9559dec commit af750c0

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

Sprint-1/fix/median.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ function calculateMedian(list) {
2424
return null;
2525
}
2626

27-
const sorted = [...numbers].sort((a, b) => a - b);
27+
const sorted = numbers.sort((a, b) => a - b);
2828

2929
const middle = Math.floor(sorted.length / 2);
3030

0 commit comments

Comments
 (0)