From 78e466eb0f89e82042aced7811be4192c39d6609 Mon Sep 17 00:00:00 2001 From: kevinnls <57634663+kevinnls@users.noreply.github.com> Date: Mon, 20 Sep 2021 16:44:01 +0530 Subject: [PATCH] use new fname --- bubblesort/main.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/bubblesort/main.c b/bubblesort/main.c index aa98de7..345cac5 100644 --- a/bubblesort/main.c +++ b/bubblesort/main.c @@ -1,7 +1,7 @@ #include #include #include -#include "../debug/debug.h" +#include "../_headers/debug.h" int* sort(int*, int); void swap(int*, int, int); @@ -35,12 +35,12 @@ int main(int argc, char** argv){ int* sort(int* arr, int length){ if(DEBUG){ - dprintf("length of array to be sorted: %d\n", length); - dprintf("elements of array to be sorted: "); + debug_msg("length of array to be sorted: %d\n", length); + debug_msg("elements of array to be sorted: "); for(int i=0; iarr[i+1]){ - if(DEBUG) dprintf("need to swap [%d]->%d and [%d]->%d\n",i,arr[i],i+1,arr[i+1]); + if(DEBUG) debug_msg("need to swap [%d]->%d and [%d]->%d\n",i,arr[i],i+1,arr[i+1]); swap(arr, i, i+1); ++changes; } @@ -56,23 +56,23 @@ int* sort(int* arr, int length){ } while (changes != 0); if(DEBUG){ - dprintf("=====\nelement post-sort are: "); + debug_msg("=====\nelement post-sort are: "); for(int i=0; i