본문 바로가기
python-algorithm

Leetcode 1295. Find Numbers with Even Number of Digits

by 무적김두칠 2021. 8. 17.

1
2
3
4
5
6
class Solution:
    def findNumbers(self, nums: List[int]) -> int:
        ans=0
        for i in nums:
            if len(str(i))%2==0:  ans+=1
        return ans
cs
반응형

댓글