Réponse acceptée

Walter Roberson
Walter Roberson le 3 Mar 2019
temp = regexp(s, '(?<=\S)\s+', 'split');
s = vertcat(temp{:});

1 commentaire

Mai Le Thai
Mai Le Thai le 3 Mar 2019
Thanks for your help!
Can you please explain this '(?<=\S)\s+'?

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

En savoir plus sur Characters and Strings dans Centre d'aide et File Exchange

Produits

Version

R2018b

Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by