Sorting is the process of structuring data in a specific format. The sorting algorithm explicitly states how to arrange data in a specific order. The most popular orders are numerical or lexicographical.
When humans understood the importance of searching speedily, they coined the term sorting. The significance of sorting stems from the fact that if data is stored in a sorted manner, data searching can be optimized to a very high level. Sorting is also used to make data more readable.
The following are a few examples of sorting in real-world scenarios.
1. Telephone Directory : The telephone directory stores…
N-Queen problem is a classical problem in the field of Artificial Intelligence and the goal is to arrange N queens on an NxN grid in such a way that no queen can “take” another queen. Queens can move horizontally, vertically, or diagonally.
Look at the following diagram which explains the problem definition that has mentioned above for 4 — queens.
Considering the history, the goal of the n-queens problem is to find Q(n), the number of different ways to arrange n-queens on an n-by-n chessboard so that no two queens are on the same row, column, or diagonal. The problem…
Let’s see how to handle the version control using TortoiseGit and Github in this article.
Nothing in life is as certain as death and taxes, so we must accept that Queen Elizabeth II will die at some point. However, as the world’s longest-reigning monarch, she has raised an entire generation who have never gone through life without her. So what will happen after she dies? When a reigning monarch dies, what protocol is followed?
Queen Elizabeth II has been alive for the majority of people’s entire lives. Upon the death of her father, the young Elizabeth Alexandra May Windsor became Queen Elizabeth II. She is the longest-reigning British monarch at 94 years old, having ascended…
We use various types of Data Structures according to the need we have. There are numerous Data Structures available in Computer Science and we are going to see about a brilliant one among them, Heaps!
Graphs are widely used nowadays. They are used in economics, aviation, physics, biology (for DNA analysis), mathematics, and other fields.
We are now in a decade that focuses on expanding the application of Artificial Intelligence (AI) in almost every sector that is possible. Since the debate started about AI, game playing has been an important and one of the most interesting applications of AI.
Claude Shannon and Alan Turing wrote the first chess programs in 1950, almost as soon as computers could be programmed. Chess, tic-tac-toe, and Go are intriguing because they provide a pure abstraction of the competition between the two players. This subjectivity is what makes game playing an appealing area for AI research.
Minimax is a decision…
What is a Stack first? Stack means a more or less orderly pile or heap.
Where will you add the new coin? If you’re allowed to take a coin, which one will be taken by you?
Welcome back to my platform!
In this tutorial I’m going to talk about three main things.
In computer science, recursion is a technique to solve the problems whose solutions depend on the smaller instance of the same problem. It defines the problem in terms of itself. It is one of the most powerful tool in writing algorithms. It comes directly from the Mathematics as there are many expressions with respect to the problems itselves.
For example, in Fibonacci sequence generation we use F(i)=F(i-1)+F(i-2) and it is a recursive opration.
Look at this example: The…
In this article let us see how to create Publisher, and Subscriber using ROS and Python in Windows.
I hope you have installed Gedit (if you have gone through HelloWorld article: There the configuration of Gedit is given).
Wait, what? Are you serious?
Yeah, it is possible to install ROS in Windows, and let us see how can this happens. First of all, for the people who are not familiar with ROS, What is ROS?
The Robot Operating System (ROS) is a robotic middleware. Even though ROS is not an operating system, it offers services built for a heterogeneous cluster of computers such as hardware abstraction, low-level device control, widely-used functionality implementation, process-to-process messaging, and package management.
If you are working on Ubuntu, it doesn’t matter. But what for Windows people? Here we go!
To install software, you…
Reading Bachelor of Science Honours in Computer Science at University of Jaffna, HND in Construction and Built Environment (Civil Engineering)