using double instead of int now for decimal and better precision. if i'm not wrong, double has better precision than float (not sure lol)

Signed-off-by: Liew Zhao Wei <zhaoweiliew@gmail.com>