#t169. 修改字符数组
修改字符数组
Modify a Character Array
Problem Description
Read in consecutive characters, change the -th character to a specified other character, and output the modified result.
Input Format
The first line contains a positive integer ().
The second line contains a string of consecutive characters.
The third line contains an integer and a character , meaning that the -th character should be changed to .
Output Format
Output the modified string.
Sample Input 1
15
congratulations
2 a
Sample Output 1
cangratulations
Sample Input 2
11
hello world
8 a
Sample Output 2
hello warld
Hint
The input string may contain whitespace, so you cannot read it directly with %s — use a line-reading function (e.g. gets/fgets/std::getline) instead.