mirror of
https://github.com/PaddiM8/kalker.git
synced 2025-01-08 14:38:50 +01:00
Fixed exponent being one too much for scientific notation.
This commit is contained in:
parent
039f79697d
commit
ec78eabd66
@ -28,7 +28,7 @@ pub fn eval(parser: &mut parser::Context, input: &str) {
|
|||||||
};
|
};
|
||||||
|
|
||||||
if use_sci_notation {
|
if use_sci_notation {
|
||||||
println!("{}{}*10^{}", sign, num, exp);
|
println!("{}{}*10^{}", sign, num, exp - 1);
|
||||||
} else {
|
} else {
|
||||||
println!("{}{}", sign, num);
|
println!("{}{}", sign, num);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user