The Algorithms - Rust

repository·master·Indexed 12 days ago

https://github.com/thealgorithms/rust

An educational collection of algorithm implementations in Rust, version 0.1.0, designed to help developers learn algorithmic concepts. The repository includes implementations of ciphers (AES, SHA-2, Caesar), data structures (B-Trees, AVL Trees, Doubly Linked Lists), searching algorithms (Binary, Exponential, Fibonacci), sorting algorithms (Timsort, Quick Sort, Merge Sort), and string algorithms (Aho-Corasick, KMP, Burrows-Wheeler transform).

Tokens
12.7K
Snippets
39
Records
89
Agent score
98%

What's inside The Algorithms - Rust

  1. Overview of The Algorithms - Rust

    master
    The Algorithms - Rust is an educational repository containing various algorithms implemented in the Rust programming language. It is designed to serve as a learning resource for developers interested in understanding algorithmic logic through Rust implementations.
  2. Overview of Sort Algorithms

    master
    This module provides a collection of various sorting algorithm implementations in Rust. The algorithms range from simple educational examples like Bogo-sort to efficient, production-grade hybrid algorithms like Timsort. Each algorithm is implemented in its own module within the src/sorting/ directory.
  3. Use String Algorithms in Rust

    master

    The the_algorithms_rust repository provides implementations of various string-based algorithms. You can use these to perform tasks such as dictionary matching, pattern searching, compression, and calculating string metrics.

    Available algorithms include:

    • Aho-Corasick: Dictionary-matching for locating multiple strings simultaneously.
    • Burrows-Wheeler transform: Reorganizes strings into runs of similar characters for compression.
    • Knuth Morris Pratt (KMP): Linear-time pattern searching.
    • Manacher: Finding the longest palindromic substring in linear time.
    • Rabin Karp: Hashing-based pattern searching.
    • Hamming Distance: Measuring the number of substitutions required to transform one string into another (requires equal length strings).
    • Run Length Encoding: Lossless data compression by storing sequences of identical data as a value and a count.
  4. Explore Data Structures

    master

    The data_structures module contains various fundamental data structures and probabilistic structures:

    • Trees: AVL Tree, B-Tree, Binary Search Tree, Fenwick Tree, Lazy Segment Tree, RB Tree, Segment Tree, Segment Tree Recursive, Treap, Trie, Veb Tree
    • Linear/Other: Graph, Hash Table, Heap, Linked List, Queue, Stack Using Singly Linked List, Union Find
    • Probabilistic: Bloom Filter, Count Min Sketch
    • Specialized: Floyds Algorithm, Range Minimum Query
  5. Explore Searching algorithms

    master

    The repository includes several searching techniques:

    • Standard Search: Binary Search (Iterative & Recursive), Linear Search, Exponential Search, Jump Search, Interpolation Search, Ternary Search.
    • Specialized Search: Fibonacci Search, Saddleback Search, Quick Select, K-th Smallest (including Heap-based implementation).
    • Other: Moore Voting.
  6. Explore Bit Manipulation algorithms

    master

    The bit_manipulation module contains various low-level bitwise operations and algorithms, such as:

    • Bit Counting/Finding: Counting Bits, Highest Set Bit, Rightmost Set Bit, Trailing Zeros
    • Properties: Is Power of Two, Hamming Distance, Unique Number
    • Transformations: Binary Coded Decimal, Binary Shifts, N Bits Gray Code, Reverse Bits, Swap Odd and Even Bits, Two's Complement
    • Arithmetic: Sum of Two Integers
    • Other: Missing Number, Previous Power of Two
  7. Explore Backtracking algorithms

    master

    The repository contains several implementations of backtracking algorithms. You can find specific implementations for tasks such as:

    • Combinations: All Combinations of Size K
    • Graph Problems: Graph Coloring, Hamiltonian Cycle, N-Queens
    • Puzzles/Games: Knight Tour, Sudoku, Rat in Maze
    • Mathematical/Logic: Parentheses Generator, Permutations, Subset Sum
  8. Explore Conversions

    master

    The conversions module provides utilities for converting between different number systems, units, and formats:

    • Number Systems: Binary, Decimal, Hexadecimal, Octal, Roman Numerals
    • Physical Units: Energy, Length, Pressure, Speed, Temperature, Volume, Weight
    • Color/Coordinate: RGB-CMYK, RGB-HSV, Rectangular to Polar
    • Other: IPv4, Order of Magnitude, Time