Skip to content

Commit 4be45f9

Browse files
authored
Update 07_Move_Zeroes.md
1 parent 4807fcc commit 4be45f9

File tree

1 file changed

+8
-6
lines changed

1 file changed

+8
-6
lines changed

codewars/07_Move_Zeroes.md

+8-6
Original file line numberDiff line numberDiff line change
@@ -22,21 +22,23 @@ function pushZerosToEnd(arr) {
2222
}
2323

2424
console.log(pushZerosToEnd([0, 1, 2, 0, 3, 0, 5, 6]))
25-
25+
```
2626
==============================================================
27-
27+
```js
2828
var pushZerosToEnd = function (arr) {
2929
return arr.filter(function(x) {return x !== 0}).concat(arr.filter(function(x) {return x === 0;}));
3030
}
31-
32-
=============================================================
31+
```
32+
==============================================================
33+
```js
3334
var pushZerosToEnd = function (arr) {
3435
return arr
3536
.filter((val) => val !== 0)
3637
.concat(arr.filter((val) => val === 0));
3738
}
38-
39-
=============================================================
39+
```
40+
==============================================================
41+
```js
4042
var pushZerosToEnd = function (arr) {
4143
var result = [];
4244

0 commit comments

Comments
 (0)