maitakedayo_rpn_calc

Crates.iomaitakedayo_rpn_calc
lib.rsmaitakedayo_rpn_calc
version0.1.1
sourcesrc
created_at2023-06-14 09:30:32.51722
updated_at2023-06-14 09:30:32.51722
descriptionRPN(Reverse Polish Notatio) library
homepagehttps://github.com/maitakedayo/
repository
max_upload_size
id889949
size3,596
(maitakedayo)

documentation

README

RPN(Reverse Polish Notation) Calc

Reverse Polish notation (RPN) Calc.

Example

fn main() {
    let src = String::from("1 2 + 3 * ");
    let a = rpn_calc::eval(src).unwrap();
    println!("{}", a); // →9
}
fn main() {
    let result = rpn_calc::eval_str("1 2 3 * +");
    println!("{}", result); // →7
}
Commit count: 0

cargo fmt