Skip to content

Commit

Permalink
Fixed exponent being one too much for scientific notation.
Browse files Browse the repository at this point in the history
  • Loading branch information
PaddiM8 committed Jun 12, 2020
1 parent 039f796 commit ec78eab
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion kalk_cli/src/output.rs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ pub fn eval(parser: &mut parser::Context, input: &str) {
};

if use_sci_notation {
println!("{}{}*10^{}", sign, num, exp);
println!("{}{}*10^{}", sign, num, exp - 1);
} else {
println!("{}{}", sign, num);
}
Expand Down

0 comments on commit ec78eab

Please sign in to comment.