0% found this document useful (0 votes)
38 views2 pages

Lab Assignment 1

The document describes a lab assignment with two problems. Problem 1 involves comparing the runtime of linear search and binary search on random data sets of increasing sizes using line charts and tables. Problem 2 compares the runtime of bubble sort and merge sort on the same random data sets. The report must include algorithm complexities, programming details, and operating system/hardware used. Samples of the required table and line chart formats are provided.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
38 views2 pages

Lab Assignment 1

The document describes a lab assignment with two problems. Problem 1 involves comparing the runtime of linear search and binary search on random data sets of increasing sizes using line charts and tables. Problem 2 compares the runtime of bubble sort and merge sort on the same random data sets. The report must include algorithm complexities, programming details, and operating system/hardware used. Samples of the required table and line chart formats are provided.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

Lab Assignment 1

Problem 1
Show the comparison of runtime of linear search and binary search using line chart and table.
Execute both algorithms 6 times on same data (use random integer generators), where input
data size are: 50000, 100000, 150000, 200000, 250000 and 300000. Please report worst case
runtimes so that the search item is not found in the input data.

Problem 2
Show the comparison of runtime of bubble sort and merge sort using line chart and table.
Execute both algorithms 6 times on same data (use random integer generators), where data
size are: 50000, 100000, 150000, 200000, 250000 and 300000. In each execution, sort the data
in ascending order.

Include the following information in your report.


Complexity of these algorithms in Big-O notation
Programming language
IDE
Special libraries (if any)
Operating system
Hardware details (CPU and RAM information)

You can use any programming language, IDE and library. You can use any implementation of
these algorithms available in the Internet. Dont run them in server or cloud platform. Execute
them in your personal computer.

Submission deadline: February 21, 23 (to respective lab section TAs)


Sample result (table and line chart format):
Runtime of Alg X (in Runtime of Alg Y (in
Data size seconds) seconds)
50000 14.05 0.01
100000 56.9 0.02
150000 85.35 0.03
200000 229.44 0.05
250000 286.8 0.0625
300000 513.34 0.065

You might also like