Merge pull request #319 from shivamagarwal1999/patch-2

Update BubbleSort.c
This commit is contained in:
Ashwek Swamy 2019-10-11 22:51:27 +05:30 committed by GitHub
commit e2d3675bc7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -29,7 +29,7 @@ void swap(int *first, int *second){
void bubbleSort(int arr[], int size){
for(int i=0; i<size-1; i++) {
for(int j=0; j<size-1; j++) {
for(int j=0; j<size-1-i; j++) {
if(arr[j]>arr[j+1]) {
swap(&arr[j], &arr[j+1]);
}