prettyprint 0.8.1

Print beautifully formatted files and strings to your terminal
Documentation
1
2
3
4
5
  // Output the square of a number.
  fn print_square(num: f64) {
      let result = f64::powf(num, 2.0);
      println!("The square of {:.2} is {:.2}.", num, result);
  }