gaboshlib/g_num_is_approx.sh aktualisiert
This commit is contained in:
parent
301bcde417
commit
09c821e824
@ -10,8 +10,8 @@ function g_num_is_approx {
|
|||||||
|
|
||||||
g_num_valid_number "${f_num}" "${f_base}" "${f_percentage_up}" "${f_percentage_down}" || return 1
|
g_num_valid_number "${f_num}" "${f_base}" "${f_percentage_up}" "${f_percentage_down}" || return 1
|
||||||
|
|
||||||
local f_from=$(echo "${f_base} - (${f_base} / 100 * ${f_percentage_down})" | bc -l)
|
local f_from=$(g_calc "${f_base} - (${f_base} / 100 * ${f_percentage_down})")
|
||||||
local f_to=$(echo "${f_base} + (${f_base} / 100 * ${f_percentage_up})" | bc -l)
|
local f_to=$(g_calc "${f_base} + (${f_base} / 100 * ${f_percentage_up})")
|
||||||
|
|
||||||
g_num_is_between ${f_num} ${f_from} ${f_to}
|
g_num_is_between ${f_num} ${f_from} ${f_to}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user