Skip to content

Latest commit

 

History

History
32 lines (25 loc) · 952 Bytes

File metadata and controls

32 lines (25 loc) · 952 Bytes

Sorting-And-Searching-Algorithms-Comparison

A program that measures the speed of various sorting and searching algorithms by analysing a giant phonebook.

Algorithms included

  • Linear Searching
  • Jump Searching
  • Binary Searching
  • Hashtable Searching
  • Bubble Sorting
  • Quick Sorting

Output Example

Start searching (linear search)...
Found 500 / 500 entries. Time taken: 1 min. 56 sec. 328 ms.

Start searching (bubble sort + jump search)...
Found 500 / 500 entries. Time taken: 9 min. 15 sec. 291 ms.
Sorting time: 8 min. 45 sec. 251 ms.
Searching time: 0 min. 30 sec. 40 ms.

Start searching (quick sort + binary search)...
Found 500 / 500 entries. Time taken: 1 min. 21 sec. 996 ms.
Sorting time: 1 min. 17 sec. 381 ms.
Searching time: 0 min. 4 sec. 615 ms.

Start searching (hash table)...
Found 500 / 500 entries. Time taken: 0 min. 4 sec. 256 ms.
Creating time: 0 min. 4 sec. 121 ms.
Searching time: 0 min. 0 sec. 135 ms.````