Any suggestions for this code?

2 ビュー (過去 30 日間)
J
J 2015 年 4 月 20 日
コメント済み: J 2015 年 4 月 20 日
I'm trying to prompt the user for coordinates in the following matter, but it is not working. Any advice would be great. Thank you all for your time in advance.
[x1, y1] = input('Please enter the first coordinates in this form [# #]: ');
[x2, y2] = input('Please enter the second coordinates in this form [# #]: ');
[x3, y3] = input('Please enter the third coordinates in this form [# #]: ');

採用された回答

pfb
pfb 2015 年 4 月 20 日
tmp = input('Please enter the first coordinates in this form [# #]: ');
x1=tmp(1);
y1=tmp(2);
and so on...
  1 件のコメント
J
J 2015 年 4 月 20 日
Outstanding! Many thanks pfb :)

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

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeMATLAB についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by