Skip to content

ianliu/recalc

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

recalc

I've made this project to learn a little bit about the Rust programming language. It is a reactive calculator, meaning that expressions are always lazily evaluated. Take a look at the following example:

> x = 10
x = 10
> y = 2 * x
y = 20
> x = 20
x = 20
> y
40

Getting Started

Clone this repo and run cargo run. You will be greeted with a REPL where you can input commands. You can use

  • +, -, *, /, and ^ to perform calculations;
  • pi and e constants;
  • sin, cos, and tan functions;
  • = to define variables.

Disclaimer

This is a toy project, there are bugs and they can bite you. For instance, don't try this: x = x.

Future

I would like to advance this project to include the following features:

  • Pin board, an area showing pinned variables
  • Array formulas

About

Reactive calculator, or excel in a REPL!

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages