String Function MATLAB help
古いコメントを表示
What is a MATLAB function you could use to find the number of characters in a string by using a single function call without displaying the string?
回答 (1 件)
Walter Roberson
2019 年 3 月 23 日
0 投票
2 件のコメント
Laura Blydenburgh
2019 年 3 月 23 日
Walter Roberson
2019 年 3 月 23 日
That has nothing to do with string length. You simply need to add semi-colon to the end of the lines.
str = "Hello World"; %semi-colon tells MATLAB not to display result
L = strlength(str) %no semi-colon so that MATLAB will display result
カテゴリ
ヘルプ センター および File Exchange で Characters and Strings についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!