Python/data_structures
Immiel 2e2e1b656c
singly_linked_list: Added additional documentation, type hints and test cases (#4988)
This is a followup to https://github.com/TheAlgorithms/Python/pull/4973#issuecomment-933117382

As per given suggestion, I've added type hints to certain methods that don't have them.  I have also added documentation and example doctests as a usage example for (most of) those that don't have them.

I have also added another test case following the previous test case's format. I noticed that the existing test case from previous pull request might be redundant with the ones I've made, so I decided to create a specific situation where the linked list would have to keep different kinds of data types for each node, in `test_singly_linked_list_2` test function.

Some minor changes in strings has been done to keep things consistent with other parts of the document. If it is undesirable, please let me know.
2021-10-20 16:08:39 +08:00
..
binary_tree Fixed typo (#5439) 2021-10-19 21:39:15 +02:00
disjoint_set Add type annotations (#4814) 2021-10-12 00:34:30 +08:00
hashing Pyupgrade to Python 3.9 (#4718) 2021-09-07 13:37:03 +02:00
heap Pyupgrade to Python 3.9 (#4718) 2021-09-07 13:37:03 +02:00
linked_list singly_linked_list: Added additional documentation, type hints and test cases (#4988) 2021-10-20 16:08:39 +08:00
queue Update LinkedQueue (#3683) 2020-10-24 12:16:37 +02:00
stacks Pyupgrade to Python 3.9 (#4718) 2021-09-07 13:37:03 +02:00
trie Add __init__.py files in all the directories (#2503) 2020-09-28 19:42:36 +02:00
__init__.py Add __init__.py files in all the directories (#2503) 2020-09-28 19:42:36 +02:00