フィルターのクリア

Printing Certain Number from a Vector

4 ビュー (過去 30 日間)
Faris Amzar Mohamad Azrai
Faris Amzar Mohamad Azrai 2020 年 6 月 4 日
コメント済み: Stephen23 2020 年 6 月 4 日
Hello, can anyone help me? I want to print the numbers which is not 0 from this vector using fprintf. So, basically, i want to print out the numbers 1 and 10 in one line and in a vector form in the statement.
vector = [0 0 0 1 10];
fprintf(....)

採用された回答

KSSV
KSSV 2020 年 6 月 4 日
disp(vector(vector~=0))

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeGet Started with MATLAB についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by