# Python program to find the digits which are absent in a given mobile number.

## Topic: Python program to find the digits which are absent in a given mobile number.

Solution

def absent_digits(n): all_nums = set([0, 1, 2, 3, 4, 5, 6, 7, 8, 9]) n = set([int(i) for i in n]) n = n.symmetric_difference(all_nums) n = sorted(n) return n print(absent_digits([9, 8, 3, 2, 2, 0, 9, 7, 6, 3]))

List all Python Programs