COMPARISON OF SIMPLE ALGORITHM DATA (SORTING) CONTROL METHODS ON SELECTION AND BUBBLE SORT

Abstract-In the data there is a sorting process which is sorting data with certain rules, so that it will be arranged in the algorithm. Algorithms are steps that will solve a problem in the data, algorithms have a variety of settlement methods, one of which is the sorting method. Data sorting (Sorting) contains different types such as Bubble Sort, Insertion Sort, Merge Sort, Quick Sort, Selection Sort, and Shell Sort. The following will explain how to process the data sequencing of each method using a simple algorithm, especially in the Selection Sort method, and Bubble Sort.


Introduction
Technology plays an important role in everyday life.Programming language is needed in certain needs, because our work at this time always follows technological advancements.For the sake of increasing community satisfaction, the most highlighted side.This of course further strengthens its position as a language of instruction between humans that can be understood, and can be run by a programmer.It has become a part of the life of today's society, not only as a source of information, but also a lifestyle and culture.So that many gamers make programs that facilitate work in the fields of statistics and information, namely in terms of sorting data.
From the data sorting program there are algorithms that are used to sort a data, one of which is sorting.The advantages of sorting are to facilitate data search, and also so that the data is more systematic because it is ordered.So that the sorting method using sorting is very useful in searching data.Sorting or sorting is the process of compiling elements from random initial inputs into final output arranged in a certain order [4].

Research Methods 2.1 Selection Sort Method
Sorting data with the Selection method can be explained simply by finding the smallest data (Ascending) or searching for the largest data (Discending) from the initial data arrangement from the first data to the last data.After the smallest data is found then exchange it with the first data.After that the smallest data is searched again but starting from the second data to the last data so that the data is in sequence.
According to Abidin [1] the selection sort method is an improvement from the bubble sort method by reducing the number of comparisons.Selection sort is a sorting method by looking for the smallest data value starting from data in position 0 to position N-1.If there are N data and data collected from the order of 0 to N-1, the sorting algorithm using the selection sort method is as follows: 1) Find the smallest data in j = 0 to j = N-1 intervals.
2) If the smallest data position is found at the postal position, exchange the data in the position of the post with data in position i if k.
3) Repeat steps 1 and 2 with j = j + i up to j = N-1, and so on until j = N -1.

Bubble Sort Method
This algorithm is a simple sorting algorithm and is usually studied as a subject around sequencing.This Bubble Sort algorithm is a sorting process that gradually moves to the right position because that is called Bubble, which means bubbles.This algorithm will sort data from the largest to the smallest (ascending) or vice versa (descending).Simply put, the Bubble Sort algorithm can be defined as sorting by exchanging data with the data next to it continuously until in a certain iteration there is no change.To learn this Bubble Sort algorithm we only need to understand the method used to sort data, simply this algorithm use comparisons in operations between elements [5].The first step is looking for the smallest data from the 1st data to the 8th data from.Found value 5 in the 8th data.Exchange the value of 5 with a value of 45 in the first data.Next, the second step looks for the smallest data starting from the 2nd data sequence to the last data.The value of 15 is found in the 3rd data.Exchange the value of 15 with a value of 25 in the second.Then the third step is found in the value of 25 which is already at number 3 so that there is no exchange of positions with other data.Then the 4th data is not suitable because there is a smaller value in the 6th data, exchange the value 35 with the value of 65th in the 4th data.The 5th data is not suitable because there is a smaller value in the 8th data.The 6th data is not suitable because there is a smaller value in the 8th data.The 7th data is not suitable because there is a smaller value in the 8th data.Data has been sorted in ascending order.To get the reverse data sequence in descending, that is, the order of the largest data to the smallest data, enough to change the value of the data being searched into the largest data.Compare the first data with the second data, if the first data is bigger than the second data, then exchange places.In the first comparison the value of 45 is greater than the value of 25.Then compare the second data with the third data, if the second data is greater than the third data, then exchange places.In the second comparison the value of 45 is greater than the value of 15.Compare the 3rd and 4th data there is no change in the order because the value of 45 is smaller than the value of 65 so that the data arrangement is fixed.Compare the 4th and 5th data, there is a change in the order because the value of 65 is greater than the value of 55.Compare the 5th and 6th data, there is a change in the order because the value of 65 is greater than the value of 35.Data 6th and 7th there is no change in the order because the value of 65 is smaller than the value of 75.The 7th and 8th data changes occur because the value of 75 is greater than the value of 5.After comparing all data from the 1st to the 8th data in stages, it turns out that the data order has not been sorted, so the process continues until the data is actually sorted.Compare again the data has been processed before.The first data with the second data, if the 1st data is bigger the 2nd data, then exchanging places.In the first comparison the value of 25 is greater than the value of 15.Compare the second and third data, there is no change in the order because the value of 25 is smaller than the value of 45.Compare the 3rd and 4th data, there is no change in order because the value is 45 small from the value of 55.Compare the 4th and 5th data, there is a change in the order because the value of 55 is greater than the value of 35.Compare the 5th and 6th data there is no change in the order because the value of 55 is greater than the value of 65.Data on the 6th and 7th changes in the order because the value of 65 is greater than the value of 5.After comparing all data from the 1st to the 8th data in stages, it turns out that the data order has not been sequenced as well, so the process continues until the data is actually sorted.Compare again the data has been processed before.Compare the 1st and 2nd data, there is no change in the order because the value of 15 is smaller than the value of 25.Compare the 2nd and 3rd data, there is no change in the order because the value of 25 is smaller than the value of 45.Compare the 3rd data and fourth there is a change in the order because the value of 45 is greater than the value of 35.Compare the 4th and 5th data there is no change in the order because the value of 45 is smaller than the value of 55.Compare the 5th and 6th data occurs change in order because the value of 55 is greater than the value of 5.For the comparison of the 6th and 7th data, the 7th and 8th data data do not exchange because they are sorted.For comparison of the 1st and 2nd data, the 2nd and 3rd data, the third and fourth data lastly do not exchange data.Next, the 4th data and 5th data are exchanged because 45 is greater than 5.For the comparison of the 5th and 6th data, the 6th and 7th data, the 7th and 8th data are not exchanged for comparison of 1st and 2nd data, 2nd and 3rd data, data does not exchange.Then the 3rd data and 4th data are exchanged because 35 is greater than 5.For comparison of the 4th and 5th data, the 5th and 6th data, the 6th and 7th data, the 7th and 8th data last.Because the data has not been sequenced we do the previous process again.For comparison of the 1st and 2nd data, the data does not exchange, because the previous data is smaller than the data afterwards.Then the second data and the third data are exchanged because 25 is greater than 5.For the comparison of the 3rd and 4th data, the 4th and 5th data, the 5th and 6th data, the data 6 and 7, the last 7th and 8th data can be seen not exchanging data, because the previous data is smaller than the data afterwards.Because almost sequential data we do the previous process again.For comparison of the 1st and 2nd data, the data is exchanged, because the value of 15 is greater than the value of 5. Until this step the data is in order, but if not then the comparison process and place conversion can be done until the last step by staying comparing the first and second data so that the data obtained in full order from the smallest to the left and the most to the right.The data is in ascending order.To get the descending data order by descending, the order of the largest data to the smallest data, simply by changing the value of the data being searched to be the largest data.

Conclusions
Sorting data is indeed quite diverse, but in this journal we only use 2 methods, namely bubble sort and selection sort.Thus in the process the fastest method of the two methods above is selection sort compared to the bubble sort method which takes a lot of time in the final process.Of course these 2 methods have their own

Table Selection Sort MethodsTable 1 .
Preliminary data process the selection sort method

Table 3 .
Preliminary data on the process of the bubble sort method

Table 4 .
Data on the process of the bubble sort method

Table 5 .
Continued data on the bubble sort method process

Table 6 .
Data on the process of the bubble sort method

Table 7 .
Data on the process of the bubble sort method

Table 8 .
Data on the process of the bubble sort method

Table 9 .
Advanced data on the process of the bubble sort method

Table 10 .
Continued process of the bubble sort method

Table 11 .
Data on the manual results of the final process of the bubble sort method