フィルターのクリア

I need to repeat a word using a loop

1 回表示 (過去 30 日間)
Thishan Dharshana Karandana Gamalathge
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 日
for a=1:7
fprintf('\nHello'); %\n for new line
end
  1 件のコメント
Thishan Dharshana Karandana Gamalathge
This is acceptable. However, at the end of last "Hello" the icon ">>" follows.

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

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeLoops and Conditional Statements についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by