Download as pdf or txt
Download as pdf or txt
You are on page 1of 4

Yash Rughwani

0801IT211098

LAB ASSIGNMENT – 4

1. Write a r program to create a blank matrix.

2. Write a r program to create a matrix taking a given vector of numbers as


input.display the matrix (take numbers from 50 to 65)

3. Write a r program to access the element at 3rd column and 2nd row ,only the 3rd row and
only the 4th column of a given matrix.
Yash Rughwani

0801IT211098

4. Write a r program to create two 2*3 matrix and add,subtract,multiply and divide the
matrixes.
Yash Rughwani

0801IT211098

5. Print a 3*3 matrix using for loop.

6. Create m, a 10*10matrix filled with random numbers between 0 and 4 (use runif() to create
the random numbers).
Yash Rughwani

0801IT211098

7. Multiply m with itself (matrix multiplication).

8. Write a r program to concatenate two given matrixes row wise and column wise.

You might also like