printРабочее место участника

printЗадачи

1454. Add one

Ограничения: время – 1s/2s, память – 64MiB Ввод: input.txt или стандартный ввод Вывод: output.txt или стандартный вывод copy
Послать решение Blockly Посылки Темы Где Обсудить (0)

Your task is the most trivial one: given non-negative integer `N`, output `N\ +\ 1`.
The only complication is that the integer is given in an unknown base between 2 and 36 inclusive. Because of that, your program should output all possible distinct answers in lexicographically increasing order.
Input file format
Input file contains integer `N` composed of digits from 0 to 9 and latin capital letters from A to Z, without leading zeroes.
Output file format
Output file must contain all possible distinct answers, one per line. Answers must be output in the same format as input.
Constraints
`N` contains from 1 to 100 digits

Sample Input 1

32

Sample Output 1

33

Sample Input 2

9

Sample Output 2

10
A
Source: NEERC ICPC, Far Eastern subregion, 2009
loading