/warehouse-locations

Analysis of the Merge Sort, Insertion Sort and Linear Search algorithms

Primary LanguageC++

warehouse-locations

This is an Analysis of Algorithms Project.
Merge Sort, Insertion Sort, Linear Seach algorithms are used.
The program finds nearest K warehouse locations among N warehouse locations.

Expected input file: warehouselocations.txt
Expected command line format: ./program N K algorithmType(IS, MS or LS) x-axis y-axis
Sample: ./program 100000 10 MS 1234 5678

N : Total number of locations to be sorted
K : Number of closest locations to be found
algorithmType : Method to be used to solve the problem (Insertion Sort(IS), Merge Sort(MS) or Linear Search(LS))
x-axis: X-axis information of the point that closest K location will be found
y-axis: Y-axis information of the point that closest K location will be found

The program is tested with GNU C++ compiler in Linux.
Successful output file (output.txt) is achieved.