Skip to content

Algorithms and Data Structures of all kinds written in Rust.

Notifications You must be signed in to change notification settings

ronald0098/rust-algorithms

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

44 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Classic Algorithms in Rust

This repo contains the implementation of various classic algorithms for educational purposes in Rust. Right now, it is in its early stages, but the plan is to include a comprehensive list of algorithms. Contributions are welcome!

The main goal right now is to match the current algorithms implemented in https://github.com/TheAlgorithms/Rust.

Setup

This repo is only for educational purposes. It is meant to be used as a reference material. Thus, it is written as a library instead of a binary.

The way to check the execution of an algorithm is running the tests, which you can do using:

cargo test

Algorithms

Sorting Algorithms

  • Bubble
  • Counting
  • Heap
  • Insertion
  • Merge
  • Quick
  • Radix
  • Selection
  • Shell

Graphs

  • Dijkstra
  • Kruskal's Minimum Spanning Tree
  • Prim's Minimum Spanning Tree
  • BFS
  • DFS

Dynamic Programming

  • 0-1 Knapsack
  • Edit Distance
  • Longest common subsequence
  • Longest increasing subsequence
  • K-Means Clustering
  • Coin Change
  • Rod cutting
  • Egg Dropping Puzzle

Data Structures

  • Queue
  • Stack
  • Heap
  • Linked List
  • Graph
  • Trie
  • Binary Search Tree
  • B-Tree
  • AVL Tree

String Matching

  • Naive
  • Rabin Carp
  • Finite Automaton
  • Knuth Morris Pratt

General

  • Convex Hull: Graham Scan
  • N-Queens
  • Graph Coloring
  • Tower of Hanoi

Ciphers

  • Transposition

Bit Manipulation

  • Bit Distance
  • Bits Length
  • Clear Bit
  • Count Ones
  • Divide By Two
  • Get Bit
  • Is Even
  • Is Positive
  • Is Power Of Two
  • Multiply By Two
  • Multiply Signed
  • Multiply Unsigned
  • Set Bit
  • Twos Complement
  • Update Bit

Contributing

See CONTRIBUTING.md

About

Algorithms and Data Structures of all kinds written in Rust.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Rust 100.0%