採用された回答

Image Analyst
Image Analyst 2020 年 11 月 21 日

1 投票

Use input() or ginput() to ask the user for the two points.
[x, y] = ginput(2);
Instead of the square root symbol, use sqrt():
d = sqrt((x1-x2)^2 + (y1-y2)^2)
extract x1 and x2 from x or else use x(1) and x(2).

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File ExchangeData Exploration についてさらに検索

質問済み:

2020 年 11 月 21 日

回答済み:

2020 年 11 月 21 日

Community Treasure Hunt

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

Start Hunting!

Translated by