From 81527b3e049c8675249d095f1b270834cd44f758 Mon Sep 17 00:00:00 2001 From: Meowmaster Date: Mon, 20 Feb 2023 19:33:21 +0530 Subject: [PATCH] modified the identifiers --- algorithms/C/arrays/kadanes-algorithm.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/algorithms/C/arrays/kadanes-algorithm.c b/algorithms/C/arrays/kadanes-algorithm.c index 93c2164c..18f09f41 100644 --- a/algorithms/C/arrays/kadanes-algorithm.c +++ b/algorithms/C/arrays/kadanes-algorithm.c @@ -17,16 +17,16 @@ Time Complexity: O(N) #include -int maxSubArraySum(int *array,int size) +int max_sub_array_sum(int *array,int size) { - int bestSum=0,sum=0; + int best_sum=0,sum=0; for(int i=0;isum+array[i]?array[i]:sum+array[i]; - bestSum=bestSum>sum?bestSum:sum; + best_sum=best_sum>sum?best_sum:sum; } - return bestSum; + return best_sum; } int main() @@ -43,7 +43,7 @@ int main() for(int i=0;i