To be able to compare a given list of numbers, and sort them in ascending order
compare.js file generates a random number between 0 and 10 (inclusive), which will determine the length of the list. It then adds random numbers between 1 and 50 (nclusive) to the list, until it has added the amount specified previously. Once all items are added, it then calls upon the compareCollection function, which calls upon the sortArray function to make sure the items are sorted correctly.
test.js is the testing file, which checks for:
- array of length 0
- array of length 1
- array of strings instead of integers
- array length > 1 and filled with integers
Exercise for being able to implement a number of different functions with Linked Lists without using the framework version. Functions include add, remove, search, count, and reverse.