Skip to content

Commit 76be1a4

Browse files
committed
Add default output to simple-math example
1 parent df4baab commit 76be1a4

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

examples/simple-math.rs

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,20 @@ extern crate bigdecimal;
22
use bigdecimal::*;
33
use std::str::FromStr;
44

5+
/* Default example output:
6+
7+
Hello, Big Decimals!
8+
Input (0.8) with 10 decimals: 0.8 vs 0.8)
9+
square 0.64
10+
From Prim: 3.300000000000000
11+
match test 33.90000000000000
12+
sum: 58.00000000000000
13+
components: 24.00000000000000, 34.00000000000000
14+
sum mut: 48.00000000000000
15+
0.000000000000000 IS equal to zero
16+
divide: 24.00000000000000
17+
*/
18+
519
fn main() {
620
println!("Hello, Big Decimals!");
721
let input = "0.8";

0 commit comments

Comments
 (0)