Scilab Website | Contribute with GitLab | Mailing list archives | ATOMS toolboxes
Scilab Online Help
6.0.0 - Português

Change language to:
English - Français - 日本語 - Русский

Please note that the recommended version of Scilab is 2024.0.0. This page might be outdated.
See the recommended documentation of this function

Ajuda do Scilab >> Cadeias de Caracteres (Strings) > strsubst

strsubst

substitui um string por outro dentro de um string

Seqüência de Chamamento

string_out=strsubst(string_in,searchStr,replaceStr)
string_out=strsubst(string_in,searchStr,replaceStr,[flag])

Parâmetros

string_in

matriz de strings. Os strings nos quais serão procuradas ocorrências de searchStr

searchStr

string a se procurar em string.

replaceStr

string. O string de reposição

str_out

matriz de strings. O resultado da substituição em searchStr por replaceStr em string

flag

string ("r" para expressão regular)

Descrição

strsubst substitui todas as ocorrências de searchStr em string por replaceStr.

Quando se utiliza o quarto argumento "r", searchStr deve ser um string de uma expressão regular. Então, strsubst o fará corresponder com string e substituirá de acordo com a regra expressas regulares.

Exemplos

strsubst('SCI/demos/scicos','SCI','.')
strsubst('SCI/demos/scicos','/',' ')
strsubst('2' ,'/2(]*)?$\1/' ,'0','r')

Ver Também

Report an issue
<< strstr Cadeias de Caracteres (Strings) strtod >>

Copyright (c) 2022-2023 (Dassault Systèmes)
Copyright (c) 2017-2022 (ESI Group)
Copyright (c) 2011-2017 (Scilab Enterprises)
Copyright (c) 1989-2012 (INRIA)
Copyright (c) 1989-2007 (ENPC)
with contributors
Last updated:
Tue Feb 14 15:09:46 CET 2017