Transpose x from a row vector to a column vector using the transpose operator. The program is prompting the x does not have correct values. the code i have entered is below
1 回表示 (過去 30 日間)
古いコメントを表示
TASK
Transpose x from a row vector to a column vector using the transpose operator.
The code i wrote is the following
x=[1:5;]
x=x'
Test Results:
Incorrect!
Does x have five elements? ok
Is x a column vector? ok
Does x have the correct values? Not correct
0 件のコメント
回答 (2 件)
Alan Stevens
2021 年 6 月 9 日
You probably meant
x = [1:5]; % ie the ; is after the ]
However, it seems to work ok for me as you wrote it!
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Get Started with MATLAB についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!