I want to say "Hello" seven times. How can I do it using MATLAB? I know how to do it using numbers but not using words.
Thanks.

 採用された回答

KALYAN ACHARJYA
KALYAN ACHARJYA 2018 年 3 月 17 日
編集済み: KALYAN ACHARJYA 2018 年 3 月 17 日

0 投票

for a=1:7
fprintf('\nHello'); %\n for new line
end

1 件のコメント

This is acceptable. However, at the end of last "Hello" the icon ">>" follows.

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File Exchange で Loops and Conditional Statements についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by