Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 366aa6d

Browse files
committed
add new draft
1 parent e410906 commit 366aa6d

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
2+
3+
var findNumbers = function (nums) {
4+
let count = 0;
5+
for (let num of nums) {
6+
let digit = 0;
7+
8+
while (num > 0) {
9+
digit++;
10+
num = parseInt(num / 10);
11+
}
12+
13+
if (digit % 2 === 0) count++;
14+
}
15+
16+
return count;
17+
};

0 commit comments

Comments
 (0)