replace метод

replace(self, old_value, new_value)

Заменить текст.


def replace(self, old_value, new_value):
    ...
ПараметрТипОписание
old_valuestrСтарый текст.
new_valuestrНовый текст.

replace(self, index, count, text)

Заменить текст.


def replace(self, index, count, text):
    ...
ПараметрТипОписание
indexintНачальный индекс.
countintКоличество символов.
textstrТекст.

Смотрите также