Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Hi pls don't skip any task because there is a connection between every task. Pls DON'T COPY OTHERS ANSWERS. Use 191020880 as seed generator. Please

Hi pls don't skip any task because there is a connection between every task. Pls DON'T COPY OTHERS ANSWERS. Use 191020880 as seed generator. Please provide a coding without any error and give output of the code.

Task 1: Random number generation - Create a random number generator to create a list of unique integers (each number must appear only once). It must be able to generate at least 300 integers (no repeated numbers) by using your matric ID (191020880) as a seed generator.

Task 2: Sorting Implementation - Implement merge sort, and quick sort to sort a list of integers from task 1.

Task 3: Testing - Create a main function which is able to call the number generator and all algorithms. Apply the testing procedure:

Sorting

By using the function from Task 1, generate 100 unique integers. Output the list in a 100data.txt or 100data.csv file.

Read the integers from the file in an array or linked list. Apply the algorithms to Task 4 to sort the list. Record the time taken by each of the algorithms as shown in Table 2.

Repeat the process with 200 and 300 unique integers.

Task 4: Complexity Analysis - discuss and compute the complexity of all sorting algorithms that you implemented. Put the complexity on a table as shown in Table 1 and Execution Time (in milliseconds) as shown in Table 2.

image text in transcribed

PLEASE USE C++ OR C LANGUAGE

Algorithm Complexity Table 1: Complexity Analysis Algorithm 1 Algorithm 2 Odlog n) O(n) Table 2: Execution Time (in milliseconds) Algorithm 1 Algorithm 2 Algorithm 100 integers 200 integers 300 integers

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Professional Visual Basic 6 Databases

Authors: Charles Williams

1st Edition

1861002025, 978-1861002020

More Books

Students also viewed these Databases questions