Hackerrank: Winning Lottery Ticket
Problem statement The SuperBowl Lottery is about to commence, and there are several lottery tickets being sold, and each ticket is identified with a ticket ID. In one of the many winning scenarios in the Superbowl lottery, a winning pair of tickets is:
Concatenation of the two ticket IDs in the pair, in any order, contains each digit from 0 to 9 at least once. For example, if there are 2 distinct tickets with ticket ID 129300455 and 56789, (129300455, 56789) is a winning pair.