- Data Structure
- Networking
- RDBMS
- Operating System
- Java
- MS Excel
- iOS
- HTML
- CSS
- Android
- Python
- C Programming
- C++
- C#
- MongoDB
- MySQL
- Javascript
- PHP
- Physics
- Chemistry
- Biology
- Mathematics
- English
- Economics
- Psychology
- Social Studies
- Fashion Studies
- Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Ankita Saini has Published 319 Articles
Ankita Saini
184 Views
In this article, we will learn how to write a swift program to interchange the elements of first and last in a matrix across rows. Therefore, to interchange the elements we need to swap the elements of the first row with the elements of the last row of the given ... Read More
Ankita Saini
145 Views
In this article, we will learn how to write a swift program to interchange the diagonals. Therefore, to interchange the diagonals we need to swap the elements of primary diagonal with the elements of secondary diagonal of the given matrix. For example − Original matrix: 2 4 5 6 ... Read More
Ankita Saini
201 Views
In this article, we will learn how to write a swift program to print boundary elements of a matrix. Boundary elements of a matrix are those elements that are present on the boundary of the matrix that are elements in the first row, last row, first column, and last column. ... Read More
Ankita Saini
209 Views
In this article, we will learn how to write a swift program to interchange the elements of first and last in a matrix across columns. Therefore, to interchange the elements we need to swap the elements of the first column with the elements of the last column of the given ... Read More
Ankita Saini
150 Views
In this article, we will learn how to write a swift program to display lower triangular matrix. Lower triangular matrix is a matrix in which all the elements above primary diagonal are zero. As shown in the below image: $$\mathrm{\begin{bmatrix} 1 & 0 & 0 & 0 & 0 & ... Read More
Ankita Saini
2K+ Views
In this article, we will learn how to write a swift program to calculate averages using an array. Average is defined as the ratio of the sum of the elements present in the given sequence to the total number of elements available in the given sequence. The general formula of ... Read More
Ankita Saini
345 Views
In this article, we will learn how to write a swift program to find the transpose of a matrix. Transpose of a matrix is calculated by interchange the rows of a matrix into columns or columns of a matrix into rows. For example, we have the following matrix: $$\mathrm{X\:=\:\begin{bmatrix} 13, ... Read More
Ankita Saini
544 Views
In this article, we will learn how to write a swift program to sort the elements of an array in descending order. To sort the elements of an array Swift provides an in-built function named sort(by:). This function takes one argument and then sorts the array according to the condition ... Read More
Ankita Saini
2K+ Views
In this article, we will learn how to write a swift program to sort the elements of an array in ascending order. Here we are going to use the following 2 methods: sort() function without parameter sort(by:) function with parameter To sort the elements of an array Swift ... Read More
Ankita Saini
620 Views
In this article, we will learn how to write a swift program to remove all occurrences of an element in an array. So here we use the following methods − Using an inbuilt function Without using an inbuilt function Method 1: Using the removeAll() Function To remove all the ... Read More
To Continue Learning Please Login
Login with Google