indexing into a matrix

7 views (last 30 days)
mohamed essabir
mohamed essabir on 16 Feb 2020
Commented: mohamed essabir on 16 Feb 2020
hello,
i have here a matrix called A, which is equal :
1 8 2
5 4 8
4 4 1
A = 5 1 0
4 8 7
4 4 4
4 4 1
my goal is to extract the 1st 3rd and second to last (6th) rows.
how can do it?

Accepted Answer

Sindar
Sindar on 16 Feb 2020
Edited: Sindar on 16 Feb 2020
A([1 3 end-1],:)

More Answers (0)

Tags

Products

Community Treasure Hunt

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

Start Hunting!