eolymp
bolt
Try our new interface for solving problems
Problems

Minimum number

Minimum number

Construct and output the minimum number of those digits that DO NOT occur in the input string. Zero is not used. If the input data contains all digits from 1 to 9, output 0.

Input

The input string contains any text.

Output

Print the minimum number of digits that do not appear in the input line. If the input data contains all digits from 1 to 9, print 0.

Time limit 1 second
Memory limit 128 MiB
Input example #1
1734 is not 384?
Output example #1
2569