ROT N

AtCoder
IDabc146_b
Time2000ms
Memory256MB
Difficulty
We have a string $S$ consisting of uppercase English letters. Additionally, an integer $N$ will be given. Shift each character of $S$ by $N$ in alphabetical order (see below), and print the resulting string. We assume that `A` follows `Z`. For example, shifting `A` by $2$ results in `C` (`A` $\to$ `B` $\to$ `C`), and shifting `Y` by $3$ results in `B` (`Y` $\to$ `Z` $\to$ `A` $\to$ `B`). ## Constraints * $0 \leq N \leq 26$ * $1 \leq |S| \leq 10^4$ * $S$ consists of uppercase English letters. ## Input Input is given from Standard Input in the following format: $N$ $S$ [samples]
Samples
Input #1
2
ABCXYZ
Output #1
CDEZAB

Note that `A` follows `Z`.
Input #2
0
ABCXYZ
Output #2
ABCXYZ
Input #3
13
ABCDEFGHIJKLMNOPQRSTUVWXYZ
Output #3
NOPQRSTUVWXYZABCDEFGHIJKLM
API Response (JSON)
{
  "problem": {
    "name": "ROT N",
    "description": {
      "content": "We have a string $S$ consisting of uppercase English letters. Additionally, an integer $N$ will be given. Shift each character of $S$ by $N$ in alphabetical order (see below), and print the resulting ",
      "description_type": "Markdown"
    },
    "platform": "AtCoder",
    "limit": {
      "time_limit": 2000,
      "memory_limit": 262144
    },
    "difficulty": "None",
    "is_remote": true,
    "is_sync": true,
    "sync_url": null,
    "sign": "abc146_b"
  },
  "statements": [
    {
      "statement_type": "Markdown",
      "content": "We have a string $S$ consisting of uppercase English letters. Additionally, an integer $N$ will be given.\nShift each character of $S$ by $N$ in alphabetical order (see below), and print the resulting ...",
      "is_translate": false,
      "language": "English"
    }
  ]
}
Full JSON Raw Segments