“Python Separate INT in Ziffernarray” Code-Antworten

Python Separate INT in Ziffernarray

 pythonCopyimport math
n = 13579
x = [(n//(10**i))%10 for i in range(math.ceil(math.log(n, 10))-1, -1, -1)]
print(x)
Combative Caribou

Python Separate INT in Ziffernarray

 pythonCopyimport math
n = 13579
x = [(n//(10**i))%10 for i in range(math.ceil(math.log(n, 10))-1, -1, -1)]
print(x)
# [1, 3, 5, 7, 9]
Combative Caribou

Ähnliche Antworten wie “Python Separate INT in Ziffernarray”

Fragen ähnlich wie “Python Separate INT in Ziffernarray”

Weitere verwandte Antworten zu “Python Separate INT in Ziffernarray” auf Python

Durchsuchen Sie beliebte Code-Antworten nach Sprache

Durchsuchen Sie andere Codesprachen