diff --git a/gaboshlib/g_median.sh b/gaboshlib/g_median.sh index 72b27f6..fb0e9a9 100644 --- a/gaboshlib/g_median.sh +++ b/gaboshlib/g_median.sh @@ -18,7 +18,8 @@ function g_median { if (($g_num_elements % 2 == 1)) then # odd number - g_median=${g_sorted_numbers[$g_middle]} + g_median="${g_sorted_numbers[$g_middle]}" + echo "$g_median - ${g_sorted_numbers[$g_middle]} - $g_middle" else # even number g_calc "(${g_sorted_numbers[$g_middle - 1]} + ${g_sorted_numbers[$g_middle]}) / 2"