In this task, you are given an input list A. You need to extract and sort the unique digits used in the list in ascending order. Return -1 if there is no digit in the list.

Ex Input:
['y', 'm', '121', 'h', 'm', '189', '117', '257', 'y', '181', '279', 'a', '453']

Ex Output:
1, 2, 3, 4, 5, 7, 8, 9


Ex Input:
['d', '395', 'd', '233', '271']

Ex Output:
1, 2, 3, 5, 7, 9


Ex Input:
['e', 'j', 'r', 'c', 'g', 'h', '343', 'n', '29', 'p', 'f', '357', 'c', 'w', 'h']

Ex Output:

2, 3, 4, 5, 7, 9