This repository contains the implementation of various sorting and searching algorithms in Java, along with an analysis of their running times on datasets of varying sizes.
- Insertion Sort
- Merge Sort
- Counting Sort
- Linear Search
- Binary Search
This project was undertaken as a part of the BBM204 Programming Assignment 1 for the Spring 2024 semester of BBM204 Software Laboratory II course. The goal was to implement sorting and searching algorithms and analyze their running times on datasets of changing sizes.
The implemented algorithms are available in the Main.java
file. Each algorithm is thoroughly implemented and tested.
The analysis involves:
- Determining the time required for each basic operation.
- Identifying unknown quantities describing the frequency of execution of basic operations.
- Developing a realistic model for the input data.
- Analyzing the unknown quantities assuming the modeled input.
- Calculating the total running time by multiplying the time by the frequency for each operation and adding all the products.
The dataset used for analysis is stored in the file TrafficFlowDataset.csv
.
To run the analysis, execute the main
method in the Main.java
file. Ensure that the TrafficFlowDataset.csv
file is present in the project directory.
The results of the analysis are visualized using charts generated by the showAndSaveChart
method in Main.java
. The charts depict the running times of the algorithms for different input sizes.
For further details, refer to the source code and the accompanying documentation within the repository.
Note: This project is solely for educational purposes.
For any inquiries or feedback, feel free to contact me.
BBM204 Programming Assignment 1 - Spring 2024
Author: Arya Zeynep Mete