C++ Write one program with a menu allowing a user to select either an Insertion, a Selection, a Merge or a bubble sort to run with each sort using the following data in this order for every sort. (Numbers to sort: 6, 1,13,7,11,9,2,8,15,5,3,4,12,10,14) Keep count of the total number of movement of data for each sort and at the end of running all of the sorts, print a chart showing the number of moves for each sort.
Q: Question 5 Compare and Contrast the following protocols 1.Telnet 2.FTP 3.ICMP (Windows and Unix…
A: Introduction Network protocol: The protocol is a set of rules for formatting & processing…
Q: Question 11 mah
A: Kindly post the question.
Q: Does moving to the cloud solve all of a company's IT proble
A: Cloud computing: This kind of computing makes use of shared computer resources rather than local…
Q: peculate as to which iteration of the compiler would throw an error if you tried to opend an integer…
A: Here in this question we have asked that which iteration of the compiler would throw an error if you…
Q: Rock Paper Scissors Game Instructions In the game Rock Paper Scissors, two players simultaneously…
A: Since no programming language was mentioned, the provided solution is in the C++ programming…
Q: MIPS has 32 registers and all processes occur in the 32 registers. However, you’ve (probably)…
A: The question is solved in step2
Q: define, describe and give an example for web 3.0, blockchain, NFT, crypto currency, and metaverse…
A: Your answer is given below .
Q: Think of the impact that wireless networks have on nations like Nigeria and Ghana that are still in…
A: Answer: We need to write the what is impact of the wireless network over the under developed country…
Q: Let's say we have an algorithm that runs in Θ(n5) and another algorithm that runs in Θ(n3). Would…
A: Hello
Q: euler Write a function "euler (graph)" that takes in a connected graph as its input, and then…
A: Your python program is given below as you required with output.
Q: Observe the logical sequence of digits below: (7,1,4,2,1,2,8,3,5,4,2,4,9,5,6,6,...) Mark the…
A: Solution given for the above question, We have to Mark the alternative that contains the hundred…
Q: Buses have communication difficulties.
A: Introduction: The term "bus" refers to a group of wires that are linked to one or more subsystems…
Q: These protocols are like a road map, because it has a complete picture of the network. Advanced…
A: Similar to a road map are link state routing protocols. Given that it has a complete picture of the…
Q: Exactly why do we need watchdog timers in so many embedded systems?
A: Introduction: Watchdog timer (WDT) is a safety device that brings a crashed embedded system back to…
Q: The for construction is a loops that iteratively processes a given list. Consequently, it works so…
A: ANSWER-: FALSE
Q: 17824 bits of data is to be transferred from a station A to station B. Assume a call setup time of…
A: Given data connection set up time = 0.01 s Total bits N = 17824 Total hops = 3 Distance between hops…
Q: Where does the TPC's emphasis lie, as opposed to the SPEC's?
A: SPEC and TPC: In order to define benchmarks for relational database systems, the Transaction…
Q: Looking for the code explanation
A: The updated python program is given below:
Q: Explain what are the data units at different layers of the TCP/IP protocol suite?
A: The TCP/IP protocol suite is a set of protocols that are used for communication over the internet.…
Q: Explain a 3-way TCP/IP Handshake?
A: Introduction: This may also build TCP connections—first, some essentials. TCP controls data transfer…
Q: er of spanning trees for the following graph is (show y
A: We will first know what is Spanning tree:- A spanning tree is a subgraph of a graph G = (V, E) that…
Q: Determine some of the challenges involved in developing the infrastructure for the new service's…
A: Organizations encounter the following difficulties while creating their own infrastructures: The…
Q: Explain a 3-way TCP/IP Handshake?
A:
Q: Present an O(n) time algorithm to compute the coefficients of the polynomial (1 + x)^n. How much…
A: The brief introduction of the FFT algorithm is as follows: The FFT algorithm is used to solve the…
Q: In ID3 algorithm, if we have a class which has two labels "big" and "small" where 24 instances is…
A: Below i have provided the solution to the given question
Q: Disk Parameters: Transfer size is 8K bytes, Advertised average seek is 6 ms, Disk spins at 3600 RPM,…
A: The answer is given in the below step
Q: Give a quick summary of the top five (5) most crucial aspects of a process scheduling policy.
A: Introduction Scheduling algorithm: A collection of guidelines and procedures known as scheduling…
Q: There needs to be a comparison and contrast between virtual memory and virtual machines. Do the…
A: Comparison based on definitions The virtual machine is meant to provide each operating system the…
Q: When compared to other disk scheduling algorithms, how risky is the SSTF method?
A: Introduction Shortest Seek Time First: The technique known as SSTF, or Shortest Seek Time First, is…
Q: Explain what is the Network Time Protocol?
A: Definition: Network Time Protocol (NTP) is an internet protocol used to synchronize with computer…
Q: Using appropriate pseudo code, develop an image analysis approach that is capable of counting the…
A: Image Processing Algorithms To manage image processing more precisely than was ever conceivable with…
Q: An obvious continuation is to use random numbers to create names for the stars and planets. Instead…
A: mathod given below:
Q: 0.40 0.35 0.30 0.25 0.20 0.15 0.10 0.05 0.00 -3 -2 -1 0 1 2 3 4
A: ALGORITHM : 1. Start 2. Create an array of x-values from -4 to 4 with 100 elements. 3. Create an…
Q: Because of recent technological advancements, nearly all home appliances can now talk to one another…
A: Definition: Using technological advances lets you simplify your business processes, increase…
Q: Define the following terms in English words (like kajillion, bajillion, etc.), not in scientific…
A: 1) Picosecond A picosecond can be defined as a unit of time that equals one trillionth of a second,…
Q: How to create VPN to connect to branch office of the same office? What would be the preliminary…
A: Given: We have to discuss How to create VPN to connect to branch office of the same office. What…
Q: Write down the pros and cons of using each of the three most common types of networks.
A: LAN (Local Area Network)MAN (Metropolitan Area Network)WAN (Wide Area Network) three types of…
Q: uestion 3 : For the following politically incorrect data from Quinlan: Height Hair Eyes…
A: Introduction => make sure to install and import all the dependencies before running the…
Q: Question 10 As a student attending the University of Waterloo, you are looking to rent a place for…
A: The above question is solved in step 2 :-
Q: Our hash map is built in such a way that all the information is stored in a single LinkedList. As a…
A: A hash table is a group of organised objects, so it is simple to locate them afterwards. The hash…
Q: What policies should be adopted by law enforcement agencies to monitor religious institutions?
A: The question is solved in step2
Q: What size decoder is needed to construct an 128M x 16 chip from 32M x 8 chips?
A: Given: What size decoder is needed to construct an 128M x 16 chip from 32M x 8 chips?
Q: Discuss the effect of changing energy on dmax and PDD. Explain why these effects occur.
A: PDD stands for Percentage Depth Dose.
Q: An Access Point on a WLAN can be thought of as... 1. Ethernet Switch 2. Hub on LAN 3. Gateway…
A: WLAN stands for Wireless Local Area Network.
Q: Can you explain the pros and cons of storing disk writes in a cache?
A: Disk Caching: Temporarily storing files so users may access them fast. Drive cache improves the time…
Q: Analysis: Q1: There are common attributes and methods between passengers and drivers. What is the…
A: Hello
Q: 1) A database can have both Clustered and Unclustered Indexes for the same table? True False…
A: Introduction The data rows in the table or view are sorted and stored using clustered indexes…
Q: Compared to block devices, character devices tend to transfer data more quickly. Is it the case or…
A: Compared to block devices, character devices tend to transfer data more quickly. Is it the case or…
Q: [] [] dir_euler Write a function "dir_euler(digraph)" that takes in a connected, directed graph as…
A: Algorithm of the code:- 1. Start 2. Create two empty dictionaries named in_degree and out_degree.…
Q: To what extent does disk write caching help, and where does it fall short?
A: Caching disc writes is a solution. the practise of maintaining files in a temporary storage area so…
C++
Write one program with a menu allowing a user to select either an Insertion, a Selection, a Merge or a bubble sort to run with each sort using the following data in this order for every sort. (Numbers to sort: 6, 1,13,7,11,9,2,8,15,5,3,4,12,10,14) Keep count of the total number of movement of data for each sort and at the end of running all of the sorts, print a chart showing the number of moves for each sort.
Trending now
This is a popular solution!
Step by step
Solved in 3 steps with 1 images
- Question 5 Write a C++ program to sort a collection of integers using the Merge sort.. Full explain this question and text typing work only We should answer our question within 2 hours takes more time then we will reduce Rating Dont ignore this lineThe question should be done in C++, please give explanation and running result. 1. For this question, we need to provide more information about where the mismatch of the text file is happening. Write a recursive function called list_mismatched_lines that takes 2 filenames as input arguments and displays to the screen all mismatched lines in those files. This function should use hashing techniques and shall not compare strings to detect mismatch. The signature of this function should be: void list_mismatched_lines(std::string file1, std::string file2); In file1.txt, it contains "My dear C++ class. I hope that you enjoy this assignment. " In file2.txt, it contains "My dear C++ class. I hope that you like this assignment. " Example: Running the following line of code, should print to the screen the mismatched lines only, from both files. list_mismatched_lines(file1, file2); The following output should be seen on the screen: file1.txt: I hope that you enjoy this assignment.file2.txt:…Question:- write a c++ program that sorts an unsorted list of ten integer do not use the vector library for this assignment the program must have one function using a bubble sort or a selection sort algorithm to sort the ten number the main function creats an array of ten integer that are not sorted. Function is called to sort the numbers in ascending order. Finally the main function display the sorted list.
- Use C++ Programming language Write a function that merges two sorted array-based lists into one sorted array-based list. The function takes two arrays as parameters, each holding a sorted list of integers, merges them into a single sorted list, and returns the result. Note that this function performs the merge part of the merge sort algorithm. The function should have a linear time complexity i.e. O(N), where N is the sum of the length of the two input lists it merges. Note: You must write linear Function. Functions that are not linear will not be accepted. Deliverables: A copy of your merge function code in a text file. A copy of a test program to test your function. Be sure to test all cases e.g. two empty lists, one empty only, lists with 1 element each, lists with multiple elements. Screenshots of your test runs showing your function meets specifications.3) Write a program in C to delete a node from the middle of Singly Linked List 4) Write a program in C to compute the sum of all elements in an array using pointers Note you need to get the input from the terminal. 3 5) Write a program in C to count total number of vowel or consonant in a string. 6) Write a C program to check two given integers, and return true if one of them is 30 or if their sum is 30.Below are some statements about Quicksort and Heapsort. Which of the statements is correct when sorting a large number of elements? A. Heapsort and Quicksort have the same time complexity in the mean case.B. When implementing Quicksort, an extra array is usually used in addition to the one on which the sorting is performed.C. If the first element is selected as the pivot element at Quicksort, Quicksort will be faster than Heapsort when the sequence to be sorted is already almost sorted.D. Heapsort performs the sorting on linear time at its best. Group of answer options All statements except B are correct Only statements A and C are correct Only statement A is correct All statements except D are correct All statements are correct
- Using the following instruction below, write a header class for unorderedLinkedList with a function of search, insertFirst, insertLast and deleteNode. Use the library to write a program to show an operation on an unordered linked list. write in C++ program. - Include the unorderedLinkedList.h library in the codes - Initialize a list1 and list2 as unorderedLinkedList type - Declare a variable num as integer data type - Print out an instruction for user to input a numbers ending with -99 - Get a numbers from user input - Use a while loop to insert the numbers into list1 ending with -99 - Print out the current elements in List 1 - Assign list 2 to list 1 - Print out the elements in list 2 - Print the length of list 2 - Get user input for the number to be deleted - Delete the number requested by user in list2 - Print out the elements in the list after delete operation - Print the length of list 2 - Declare the intIt variable to be linked list iterator - Print out the elements in List 1…Use C++ Programming language Write a function that merges two sorted array-based lists into one sorted array-based list. The function takes two arrays as parameters, each holding a sorted list of integers, merges them into a single sorted list, and returns the result. Note that this function performs the merge part of the merge sort algorithm. The function should have a linear time complexity i.e. O(N), where N is the sum of the length of the two input lists it merges. Deliverables: A copy of your merge function code in a text file. A copy of a test program to test your function. Be sure to test all cases e.g. two empty lists, one empty only, lists with 1 element each, lists with multiple elements. Screenshots of your test runs showing your function meets specifications.Again create a data file of random integers. Then write a program in C to implement the selection sort algorithm of Figure 3.6 using file input data. Write a separate function (method, procedure) to find the location of the largest number in the unsorted section of the list (see Figure 2.14) and have your main function call that as needed. Write your sorted list to another data file.
- code needed for python 3: You are required to investigate the number of comparisons that take place during the execution of an insertion sort. Given a list of ?N unsorted integers, use insertion sort to count the number of comparisons that it takes to arrive at the sorted list. Your insertion sort should execute from left to right. Function specifications Argument(s): integers (list) →→ a list of unsorted integers. Return: comparisons (int) →→ return the number of comparisons made to arrive at the sorted list. ### START FUNCTIONdef insertion_sort(integers): ### END FUNCTION integers = [15, 1, 2, 16, 12, 16, 9, 2, 0, 11]insertion_sort(integers.copy()) Expected output integers = [15, 1, 2, 16, 12, 16, 9, 2, 0, 11] insertion_sort(integers) == 257) Use a counting sort on a set of keys that fall between (a, b), where a and b are modest positive numbers that the user inputs. 8) For an acceptable selection of the number of buckets, implement bucket sort with an array of lists data structure to sort a list of characters, a list of floating point values, and a list of uniformly distributed integers.Given a list of n integers, write a C++ program to sort these integers usingmerge sort. Print to the screen the sorted list.The program requires that integers in the list are from user input. You can make theassumption that user input numbers are all integers and there is no improper input. Additional requirements and reminders (IMPORTANT): 1) You must use the merge sort algorithm to sort the list of integers. You mustuse recursion in your program.2) The list of integers must from user input. You may not hardcode it in your program.