cswork / OA打开练习工作台

AmazonOA #182

Find Encrypted Number

估计简单可在线判题

考点(AI 标注)模拟/实现位运算

Repeatedly form the next row from the last digits of the sums of adjacent digits until only 2 digits remain, then output them as a two-character string, keeping leading 0s.

输入格式

The first line contains n; the second line contains n digits. 2≤n≤5000, each in 0..9.

输出格式

Output exactly two digit characters; leading 0s must be kept.

样例 1

输入:

4
4 5 6 7

输出:

04

样例 2

输入:

2
0 4

输出:

04

样例 3

输入:

3
9 9 9

输出:

88

样例说明

The answers are 04, 04 and 88; the third example has only one round, and the last digit of 9+9 is 8 in both positions.