Boolean20. A three-digit number is given. Verify the truth of the statement: "All figures of a given number are different."

Solution in Python 3:

import random

N = random.randrange(100,1000)
print("Число: ", N)
d2 = int(N/100)
d1 = int((N-d2*100)/10)
d0 = N%10
print("Hundreds: ", d2)
print("Tens: ", d1)
print("Units: ", d0)
ab = (d2 != d1)
bc = (d1 != d0)
ac = (d2 != d0)
x = ab and bc and ac
print("All digits are different: ", x)