Skip to content

joao-gugel/shunting-yard-algorithm-rust

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Rust Calculator

This is a rust calculator made using shunting yard algorithm and reverse polish notation.

This project was made to learn how to build a calculator without use eval() function.

How to run?

Create a clone of this repository and enter on directory:

$ git clone https://github.com/jotavetech/shunting-yard-algorithm-rust
$ cd shunting-yard-algorithm-rust

To run this project you will also need the Rust Compiler installed.

With everything done, run it using cargo run command in your terminal and type an simple expression, without using (), just + - / * and numbers.

$ cargo run

Enter your expression:
> 20 + 10 / 2 * 3

Result of your expression is 35

References

About

Implementing shuting yard algorithm and reverse polish notation to create a simple rust calculator

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages