if i want user to to input n number of values in the input window in array form how should i do it

 採用された回答

Ameer Hamza
Ameer Hamza 2020 年 10 月 9 日

0 投票

vec = input('Enter an array: ')
run the above line and type
[1,2,3,4]
in the command window. You will get
>> vec
vec =
1 2 3 4

2 件のコメント

Tejas Mahajan
Tejas Mahajan 2020 年 10 月 9 日
I want to do this in MAtlab App Designer
Ameer Hamza
Ameer Hamza 2020 年 10 月 9 日

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

その他の回答 (1 件)

madhan ravi
madhan ravi 2020 年 10 月 9 日

0 投票

Use input() , enter the values in the form [1,5,4] an example.
doc input

1 件のコメント

Tejas Mahajan
Tejas Mahajan 2020 年 10 月 9 日
i want to do this in Matlab App Designer.

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

カテゴリ

ヘルプ センター および File Exchange で Operating on Diagonal Matrices についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by