ozgunozerk / Random-Zoo-Basics

implementation of prime finder, modular square root finder and squaring operations in RUST

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Random-Zoo-Basics

implementation of prime finder, modular square root finder and squaring operations in RUST

Prime Finder

given a number n, find the biggest prime, which is smaller than n

Modular Square Root Finder

given a number, find it's square roots, in given modulo

Modular Square Calculater

given a number, compute it's square, in given modulo


How to RUN

  1. Download the repo
  2. move to this repo's root directory in your favourite terminal
  3. run the command cargo build, check if it builds successfully
  4. run the command `cargo run

P.S. you have to have rust and cargo installed in your system


How to see the Documentation

  1. Download the repo
  2. move to this repo's root directory in your favourite terminal
  3. run the command cargo doc --open
  4. This command will open a browser, and in there, all the documentation will be provided with a user-friendly interface

How to do the Testing (both Unit and Integration tests)

  1. Download the repo
  2. move to this repo's root directory in your favourite terminal
  3. run the command cargo test
  4. you can see the results in the terminal

How to do the Benchmark Tests

  1. Download the repo
  2. move to this repo's root directory in your favourite terminal
  3. run the command cargo bench
  4. Go to this path inside this repo target/criterion/report
  5. open the index.html in your favourite browser
  6. you can see the benchmark results in your browser, with a nice user-friendly interface

About

implementation of prime finder, modular square root finder and squaring operations in RUST


Languages

Language:Rust 100.0%