Created
May 28, 2020 19:23
-
-
Save TrevorMcCormick/b346bb0ecc773afb56027cc8cea09e7a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Given a list of numbers, figure out how many have an even number of digits | |
import math | |
def numDigits(num): | |
digits = math.floor(math.log10(num))+1 | |
return(digits) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment