cswork / 每日一题打开 500 路题单

今日一题 · (北京时间)

eBayOA

Shift n-th Consonant

中等

Count consonants from the left; the n-th, 2n-th, 3n-th… consonants are replaced with the next consonant, preserving case, with z wrapping around to b. Vowels and non-ASCII letters are kept as is and are not counted.

输入格式

The first line contains n (1..10⁹), and the second line contains message (≤200000 ASCII printable characters, possibly including spaces). Only A-Z/a-z are treated as English letters; this rule is an explicit site supplement.

输出格式

Output the entire transformed line as is; spaces must be preserved.

样例 1

输入:

1
z Z abc!

输出:

b B acd!

样例 2

输入:

3
Abc xyz! 09

输出:

Abc yyz! 09

样例 3

输入:

100
Hello, World!

输出:

Hello, World!

每天北京时间 0 点换题,所有人同一道:单号日练 500 路,双号日练热门公司的 OA。当天做完,刷题日历上那一格会变成星星,每日一题的连续天数单独记。