特定の値を除く乱数の発生

例えば、1から10の範囲で15個の乱数を発生させるとき、1から10の中の特定の値を除いて行う方法はありますか。
以下の例のようにしたいです
(例)
1から10の範囲で『3』、『8』を除く15個の乱数
[5 9 10 7 2 6 2 1 5 4 5 10 2 7 1]

 Accepted Answer

Shunichi Kusano
Shunichi Kusano on 18 Jan 2021

0 votes

こんにちは。
過去に同じ質問がありましたので、リンクを載せておきますね。

1 Comment

ST
ST on 18 Jan 2021
参考になりました。
ありがとうごいます。

Sign in to comment.

More Answers (0)

Categories

Find more on 乱数発生器 in Help Center and File Exchange

Asked:

ST
on 16 Jan 2021

Commented:

ST
on 18 Jan 2021

Community Treasure Hunt

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

Start Hunting!