fprintf size without knowing the dimension
15 ビュー (過去 30 日間)
古いコメントを表示
How can I print the size of the array in one row without prior-knowing the dimension of the array?
fprintf(' %d\n',size(array));
How many %d to put there? or how to do it right?
1 件のコメント
Geoff Hayes
2017 年 7 月 14 日
John - you asked this already at https://www.mathworks.com/matlabcentral/answers/348261-how-to-print-size-of-array.
採用された回答
Honglei Chen
2017 年 7 月 14 日
編集済み: Honglei Chen
2017 年 7 月 14 日
You can just do
fprintf(' %s\n',num2str(size(array)));
HTH
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Logical についてさらに検索
製品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!