# CLAIR—Command Line Arithmetic in Rust
CLAIR is a small personal project for exploring the [Rust programming language](https://www.rust-lang.org/).
It implements arithmetic operations on lines of string (currently only stdin, but support for files as input is planned).
This is inspired by using [`awk`](https://www.gnu.org/software/gawk/manual/gawk.html) for command line arithmetics.
## Build
```shell
cargo build [--release]
```
## Run
```shell
cargo run [--release] --bin={count,mean,product,sum} [</path/to/file/as/stdin] [--help]
```
or directly form `target`:
```shell
./target/release/{count,mean,product,sum}
```
### Example
#### Count
```shell
$ ./target/release/count < Cargo.toml
24
# Reference:
$ wc -l Cargo.toml
24 Cargo.toml
```
#### Mean
```shell
# Reference:
```
#### Product
```shell
# Reference: