store string in array

1 回表示 (過去 30 日間)
Abdulkareem
Abdulkareem 2012 年 12 月 5 日
hi i want to input string consist of 5 char in array put i can't do that by using the command "input" because it is allow me to input only 1 char and when i input more than one error occur
  1 件のコメント
Evan
Evan 2012 年 12 月 5 日
編集済み: Evan 2012 年 12 月 5 日
Can you please include some example code that reproduces your problem? I'm not having any issues doing what you're describing, but it may be because I'm not understanding your problem. Some sample code is always helpful when asking a question here.
The exact error message that you're receiving is also of help.

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

採用された回答

Matt Fig
Matt Fig 2012 年 12 月 5 日
What do you mean the INPUT function only lets you input one character?
>> G = input('Enter a string: ','s')
Enter a string: red
G =
red

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeCharacters and Strings についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by