how do i prompt

3 ビュー (過去 30 日間)
janny
janny 2016 年 6 月 13 日
コメント済み: janny 2016 年 6 月 13 日
hi guys,,, am working in a binary random matrix by using the command
dec2bin((rand(50,1)*2^32)
i want to add a prmopt before this line to ask for entering column and row

採用された回答

the cyclist
the cyclist 2016 年 6 月 13 日
Use the input command.

その他の回答 (1 件)

Adam
Adam 2016 年 6 月 13 日
rowCol = input( 'Enter row and column\n' );
would work if the user inputs something like:
[9 8];
Or you could split into two prompts, one for each if you prefer.
  1 件のコメント
janny
janny 2016 年 6 月 13 日
Thanks alot

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

カテゴリ

Help Center および File ExchangeCreating and Concatenating Matrices についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by