Git Product home page Git Product logo

code-sherpas / kollections Goto Github PK

View Code? Open in Web Editor NEW
9.0 9.0 9.0 150 KB

Kollections is a Kotlin open source library to fill the gap that currently exists in the Kotlin Standard Library regarding data structures. :rocket:

License: MIT License

Kotlin 100.00%
abstract-data-types collections data-structures hacktoberfest hacktoberfest2021 kotlin kotlin-library list map queue set stack

kollections's People

Contributors

ashikka avatar dgraciac avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

kollections's Issues

Implement `fun insertAtBeginning(element:E)` for Doubly Linked List

Taking reference from issue #48 , implement the insertAtBeginning(element:E) function for a Doubly Linked List. This function will insert an element at the beginning of the Doubly Linked List.

First step

Search, read, and understand information about doubly-linked lists, and how they are implemented.

Second step

Open a pull request with the data structure implementation, and wait for comments from @code-sherpas/kollections-maintainers.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to Computer Science. Here you can find a very helpful cheat sheet.

Implement `enqueue(element: E)` function for Queues.

Taking reference from issue #15, implement the enqueue(element: E) function for a queue. This function pushed an element to the tail of the queue.

First step

Search, read, and understand information about queues and how they are implemented.

Second step

After you open a pull request with the data structure implementation, wait for comments or approval from @code-sherpas/kollections-maintainers.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to Computer Science. Here you can find a very helpful cheat sheet.
  • Compare efficiency using a dynamic array as underlying data structure vs using a linked list. Choose the most efficient.

Related resources:

Implement container tests for Singly Linked Lists

Taking reference from this dummy test, implement the container tests for a Singly Linked List.

First step

Search, read, and understand information about lists, linked lists, and singly-linked lists, and how they are implemented.

Second step

Open a pull request with the data structure implementation, and wait for comments from @code-sherpas/kollections-maintainers.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to Computer Science. Here you can find a very helpful cheat sheet.

Related resources:

Implement `insertAtEnd(element:E)` function for a Doubly Linked List

Taking reference from issue #48 , implement the insertAtEnd(element:E) function for a Doubly Linked List. This function will insert an element at the end of the Doubly Linked List.

First step

Search, read, and understand information about doubly-linked lists, and how they are implemented.

Second step

Open a pull request with the data structure implementation, and wait for comments from @code-sherpas/kollections-maintainers.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to Computer Science. Here you can find a very helpful cheat sheet.

Implement container tests for Stacks

Taking reference from this dummy test, implement the container tests for a Stack.

First step

Search, read, and understand information about stacks and how they are implemented.

Second step

Open a pull request with the data structure implementation, and wait for comments from @code-sherpas/kollections-maintainers.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to Computer Science. Here you can find a very helpful cheat sheet.

Related resources:

Implement `insertAtEnd()` function for a Singly Linked List

Taking reference from issue #12, implement the insertAtEnd() function for a Singly Linked List.

First step

Search, read, and understand information about lists, linked lists, and singly-linked lists, and how they are implemented.

Second step

Open a pull request with the data structure implementation, and wait for comments from @code-sherpas/kollections-maintainers.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to Computer Science. Here you can find a very helpful cheat sheet.

Related resources:

Implement `deleteNode(position: Integer)` function for a Singly Linked List

Taking reference from issue #12, implement the deleteNode() function for a Singly Linked List.

First step

Search, read, and understand information about lists, linked lists, and singly-linked lists, and how they are implemented.

Second step

Open a pull request with the data structure implementation, and wait for comments from @code-sherpas/kollections-maintainers.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to Computer Science. Here you can find a very helpful cheat sheet.

Related resources:

Implement `pop()` function for Stacks

Taking reference from issue #14, implement the pop() function for a Stack. This function removes an element from the top of the stack.

First step

Search, read, and understand information about stacks and how they are implemented.

Second step

After you open a pull request with the data structure implementation, wait for comments or approval from @code-sherpas/kollections-maintainers.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to Computer Science. Here you can find a very helpful cheat sheet.
  • Compare efficiency using a dynamic array as underlying data structure vs using a singly linked list. Choose the most efficient.

Related resources:

Stack implementation

First step

Search, read and understand information about stacks and how they are implemented.

Second step

You have to share a code snippet in markdown with an interface proposal for this data structure. Below you can find an interface example of an hypothetical data structure:

class MyDataStructure<E> {

    fun add(element: E) {
        TODO("Not yet implemented")
    }

    fun get(index: Int): E {
        TODO("Not yet implemented")
    }
}

Third step

After @code-sherpas/kollections-maintainers approve your interface proposal, open a pull request with the data structure implementation and wait for comments.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to the Computer Science. Here you can find a very helpful cheatsheet.
  • Compare efficiency using a dynamic array as underlying data structure vs using a singly linked list. Choose the most efficient.

Related resources:

Implement `size()` function for Queues.

Taking reference from issue #15, implement the size() function for a queue. This function finds the size of the queue.

First step

Search, read, and understand information about queues and how they are implemented.

Second step

After you open a pull request with the data structure implementation, wait for comments or approval from @code-sherpas/kollections-maintainers.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to Computer Science. Here you can find a very helpful cheat sheet.
  • Compare efficiency using a dynamic array as underlying data structure vs using a linked list. Choose the most efficient.

Related resources:

Implement `insertAtBeginning()` function for a Singly Linked List

Taking reference from issue #12, implement the insertAtBeginning() function for a Singly Linked List.

First step

Search, read, and understand information about lists, linked lists, and singly-linked lists, and how they are implemented.

Second step

Open a pull request with the data structure implementation, and wait for comments from @code-sherpas/kollections-maintainers.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to Computer Science. Here you can find a very helpful cheat sheet.

Related resources:

Implement `size()` function for Stacks

Taking reference from issue #14, implement the size() function for a Stack. This function finds the size of the stack.

First step

Search, read, and understand information about stacks and how they are implemented.

Second step

After you open a pull request with the data structure implementation, wait for comments or approval from @code-sherpas/kollections-maintainers.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to Computer Science. Here you can find a very helpful cheat sheet.
  • Compare efficiency using a dynamic array as underlying data structure vs using a singly linked list. Choose the most efficient.

Related resources:

Implement `peek()` function for Stacks

Taking reference from issue #14, implement the peek() function for a Stack. This function gets the element on the top of the stack without removing it.

First step

Search, read, and understand information about stacks and how they are implemented.

Second step

After you open a pull request with the data structure implementation, wait for comments or approval from @code-sherpas/kollections-maintainers.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to Computer Science. Here you can find a very helpful cheat sheet.
  • Compare efficiency using a dynamic array as underlying data structure vs using a singly linked list. Choose the most efficient.

Related resources:

Implement `dequeue()` function for Queues.

Taking reference from issue #15, implement the dequeue() function for a queue. This function removes an element from the head of the queue.

First step

Search, read, and understand information about queues and how they are implemented.

Second step

After you open a pull request with the data structure implementation, wait for comments or approval from @code-sherpas/kollections-maintainers.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to Computer Science. Here you can find a very helpful cheat sheet.
  • Compare efficiency using a dynamic array as underlying data structure vs using a linked list. Choose the most efficient.

Related resources:

Interface Implementation for Doubly Linked List

First step

Search, read, and understand information about doubly linked lists and how they are implemented.

Second step

You have to share a code snippet in markdown with an interface proposal for this data structure. Below you can find an interface example of a hypothetical data structure:

class MyDataStructure<E> {

    fun add(element: E) {
        TODO("Not yet implemented")
    }

    fun get(index: Int): E {
        TODO("Not yet implemented")
    }
}

Third step

After @code-sherpas/kollections-maintainers approve your interface proposal, open a pull request with the data structure implementation, and wait for comments.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to Computer Science. Here you can find a very helpful cheat sheet.

Singly Linked List implementation

First step

Search, read and understand information about lists, linked lists and singly linked lists, and how they are implemented.

Second step

You have to share a code snippet in markdown with an interface proposal for this data structure. Below you can find an interface example of an hypothetical data structure:

class MyDataStructure<E> {

    fun add(element: E) {
        TODO("Not yet implemented")
    }

    fun get(index: Int): E {
        TODO("Not yet implemented")
    }
}

Third step

After @code-sherpas/kollections-maintainers approve your interface proposal, open a pull request with the data structure implementation and wait for comments.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to the Computer Science. Here you can find a very helpful cheatsheet.

Related resources:

Implement `isEmpty()` function for Queues

Taking reference from issue #15, implement the isEmpty() function for a queue. This function checks if the queue is empty.

First step

Search, read, and understand information about queues and how they are implemented.

Second step

After you open a pull request with the data structure implementation, wait for comments or approval from @code-sherpas/kollections-maintainers.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to Computer Science. Here you can find a very helpful cheat sheet.
  • Compare efficiency using a dynamic array as underlying data structure vs using a linked list. Choose the most efficient.

Related resources:

Queue implementation

First step

Search, read and understand information about queues and how they are implemented.

Second step

You have to share a code snippet in markdown with an interface proposal for this data structure. Below you can find an interface example of an hypothetical data structure:

class MyDataStructure<E> {

    fun add(element: E) {
        TODO("Not yet implemented")
    }

    fun get(index: Int): E {
        TODO("Not yet implemented")
    }
}

Third step

After @code-sherpas/kollections-maintainers approve your interface proposal, open a pull request with the data structure implementation and wait for comments.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to the Computer Science. Here you can find a very helpful cheatsheet.
  • Compare efficiency using a dynamic array as underlying data structure vs using a linked list. Choose the most efficient.

Related resources:

Implement `push(element: E)` function for Stacks

Taking reference from issue #14, implement the push(element: E) function for a Stack. This function adds an element to the top of the stack.

First step

Search, read, and understand information about stacks and how they are implemented.

Second step

After you open a pull request with the data structure implementation, wait for comments or approval from @code-sherpas/kollections-maintainers.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to Computer Science. Here you can find a very helpful cheat sheet.
  • Compare efficiency using a dynamic array as underlying data structure vs using a singly linked list. Choose the most efficient.

Related resources:

Implement `get(index:Integer)` function for a Singly Linked List

Taking reference from issue #12, implement the get(index:Integer) function for a Singly Linked List. This function will get elements from the specified position.

First step

Search, read, and understand information about lists, linked lists, and singly-linked lists, and how they are implemented.

Second step

Open a pull request with the data structure implementation, and wait for comments from @code-sherpas/kollections-maintainers.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to Computer Science. Here you can find a very helpful cheat sheet.

Related resources:

Implement container tests for Queues

Taking reference from this dummy test, implement the container tests for a Queue.

First step

Search, read, and understand information about queues and how they are implemented.

Second step

Open a pull request with the data structure implementation, and wait for comments from @code-sherpas/kollections-maintainers.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to Computer Science. Here you can find a very helpful cheat sheet.

Related resources:

Create CONTRIBUTING.md

We need to create a CONTRIBUTING.md file that will contain all guidelines for contribution.

Implement `insertAtIndex(index: Integer)` function for a Doubly Linked List

Taking reference from issue #48 , implement the insertAtIndex(index: Integer) function for a Doubly Linked List. This function will insert elements at the specified index of the Doubly Linked List.

First step

Search, read, and understand information about doubly-linked lists, and how they are implemented.

Second step

Open a pull request with the data structure implementation, and wait for comments from @code-sherpas/kollections-maintainers.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to Computer Science. Here you can find a very helpful cheat sheet.

Implement `isEmpty()` function for Stacks

Taking reference from issue #14, implement the isEmpty() function for a Stack. This function checks if the stack is empty.

First step

Search, read, and understand information about stacks and how they are implemented.

Second step

After you open a pull request with the data structure implementation, wait for comments or approval from @code-sherpas/kollections-maintainers.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to Computer Science. Here you can find a very helpful cheat sheet.
  • Compare efficiency using a dynamic array as underlying data structure vs using a singly linked list. Choose the most efficient.

Related resources:

Implement `head()` function for a Doubly Linked List

Taking reference from issue #48 , implement the head() function for a Doubly Linked List. This function will get the element at the head of the Doubly Linked List.

First step

Search, read, and understand information about doubly-linked lists, and how they are implemented.

Second step

Open a pull request with the data structure implementation, and wait for comments from @code-sherpas/kollections-maintainers.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to Computer Science. Here you can find a very helpful cheat sheet.

Implement `isEmpty()` function for a Singly Linked List

Taking reference from issue #12, implement the isEmpty() function for a Singly Linked List. This function will check if the list is empty.

First step

Search, read, and understand information about lists, linked lists, and singly-linked lists, and how they are implemented.

Second step

Open a pull request with the data structure implementation, and wait for comments from @code-sherpas/kollections-maintainers.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to Computer Science. Here you can find a very helpful cheat sheet.

Related resources:

Implement `head()` function for a Singly Linked List

Taking reference from issue #12, implement the head() function for a Singly Linked List. This function will find the element at the head of the list.

First step

Search, read, and understand information about lists, linked lists, and singly-linked lists, and how they are implemented.

Second step

Open a pull request with the data structure implementation, and wait for comments from @code-sherpas/kollections-maintainers.

Minimum acceptance criteria

  • The implementation must be well documented with proper Javadoc at Class and function levels.
  • The implementation must be tested with automatic tests that cover all relevant cases and situations.
  • The implementation must be generic.
  • The implementation must have the expected time complexity according to Computer Science. Here you can find a very helpful cheat sheet.

Related resources:

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.