Giter Club home page Giter Club logo

datastructures.algos's Introduction

Data structures and Algorithms

This repo aims to be an introduction to simple data structures and algorithms. Users are invited to provide their own implementation of the data structures and validate the implementation through unit testing.

The implementation is provided is Java, but some things are left out:

  • Collections don't implement java.util.* interfaces to keep it simple
  • eg: iterators are left out, isEmpty(), etc
  • Performance is not relevant for naive implementations. If time allows we will delve deep into performance
  • Generics are not used to keep it simple
  • Ideally, Big-O notation would be inferred through benchmarking but that part isn't implemented yet. PRs welcome

How?

All the tests should pass by running ./gradlew test.

If you want to try your own implementation, run ./gradlew -q removeImpls to delete all code within the org.datastructures.algos.*.impl.* classes. Implement your own and make sure the tests pass.

Check the README.md on each package to see how it is supposed to work.

Contribute

Open an issue/PR with any kind suggestion or comment and I will look into it. Code, typos, unit tests, spelling, copy or any other suggestions are welcome.

TODO

  • Lists
    • Linked List
    • Array List
    • Persistent Lists
    • Sorting algorithms
  • Sets
  • Maps
    • HashMap
      • Chained
      • Open addressing
    • Persistent Maps via HAMTs
  • Stack
  • Queue
    • Priority Queue
  • Tree
    • Binary Tree
    • Red/black, AVL, etc
    • B-Tree
    • Traversal algorithms
  • Benchmarks (WIP)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.