結果 : string replace based on index python