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.

['345', 'h', '9']
3, 4, 5, 9

['479', 's', 'g']
4, 7, 9

['393', '403', 'v', 'z', '229', 'd', '259', '391', '429', '171', 's', '71', '277', 'v']

0, 1, 2, 3, 4, 5, 7, 9