icpc 2018 problem E

This commit is contained in:
Xevion
2019-08-24 19:31:42 -05:00
parent f6370de2ef
commit ca2b4f1848
4 changed files with 26 additions and 1 deletions

View File

@@ -46,7 +46,9 @@ def processWord(word):
# print(index, select, word[index:index + select[1]])
word = word[:index] + (select[0].title() if select[2].istitle() else select[0]) + word[index + select[1]:]
# word[index:index + select[1]] = select[0]
index += 1
index += len(select[0])
else:
index += 1
return word
# Process a single line