Project

Coding basics

  1. A = 1 2 3 4 5

Which define a matrix in (5 rows, 1 column)

  1. B = 1

2

3

4

5

Which define a row of the matrix

  1. C = A*B'

the number of columns in the first matrix matches the number of rows in

the second matrix. To perform elementwise multiplication, to perform this operation. C = A.*B' which gives dot product

  1. C = B*A

C = 1 2 3 4 5

2 4 6 8 10

3 6 9 12 15

4 8 12 16 20

5 10 15 20 25

  1. A(1:end)

1 2 3 4 5

Which define starting (1) to end (5)

  1. A(1:2)

1 2

Which define starting (1) to end (2)

  1. B(1:2,3)

3 row is not available in the matrix so it is not possible

  1. B(length(B)-2)

3

(5-2) length (5)

Your portfolio, next

Ship work like this
in your own course.

Talk to a career counsellor

Free 20-minute call. We'll map the right course to where you want to work.

By submitting you agree to our Terms and Privacy Policy.

Talk to a career counsellor

Free 20-minute call. We'll map the right course to where you want to work.

By submitting you agree to our Terms and Privacy Policy.