aalhour / C-Sharp-Algorithms

:books: :chart_with_upwards_trend: Plug-and-play class-library project of standard Data Structures and Algorithms in C#
MIT License
5.91k stars 1.4k forks source link

Update SkipList. Fixed Issues #137, #138, #139, #140 #147

Open Gutsonok opened 4 years ago

Gutsonok commented 4 years ago

Description

Fixed #137 . This bug occurs when _getNextLevel() method returned 0.

Fixed #138 and #139 . This bug occurs because of skip list was сircular.

Fixed #140. This bug occurs comparing method was called for null object.

I add implementaion for public T this[T item]. I think this should be work like a standard Dictionary type.

I divided a unit test for SkipList on some tests. And added additinal tests.

Checklist