This is Java programming! The current code for BstMaxHeap is printing names backwords. So please modify the code BstMaxHeap.java so it prints as the following: The heap is not empty; it contains 9 entries. The largest entry is Whitney Removing entries in descending order: Removing Whitney Removing Regis Removing Megan Removing Matt Removing Jim Removing Jared Removing Doug Removing Brittany Removing Brett
Q: For SQL, Table sec1611_prime_numbers contains the first 50 prime numbers. Use a self join to…
A: Her is the SQL query regarding the given problem:
Q: In the following cipher a sender of a message has set randomly the cipher alphabet in order to…
A:
Q: Write Algorithm for Non-commutative Gaussian Elimination Input: a set W of elements of G; Output: a…
A: Algorithm for Non-commutative Gaussian Elimination:
Q: Given a time in 12-hour notation, write a function that displays it in 24-hour notation. (C++)
A: Overview In this question we have to write a function in programming language which converts the…
Q: think about what this instruction is actually doing and consider its advantages and disadvantages…
A: Answer This instruction moves the contents of the memory location pointed by RAX into the memory…
Q: Level 4 II. Create a LunchOrder application that prompts the user for the number of hamburgers,…
A: Introduction Your data is safeguarded by getters & setters, specially when creating classes. The…
Q: Given the x-1.y-2.z-3, what is the value of y after running the following code? y+ = 2 - -/++x 03 0…
A: Here we have x is 1, y is 2 and z is 3. Next, we have expression that will update the value of y as:…
Q: jorithms, answer the following consolidated que aph:
A: Solution - In the given question, we have to find the edges that we keep for minimum-weight spanning…
Q: Why do you think x86 will not let you run the instruction below : mov [r8], [rax] In order…
A: x86 which refers to the one it is a family of complex instruction set of the computer instruction…
Q: Create a javascript code, to ask user input the name, and print out 'Good A, name, welcome to…
A: The program is written in HTML, Javascript. Check the program screenshot for the correct…
Q: Please provide a list of all the parts that typically make up an OS kernel, along with short…
A: A PC programme called a kernel serves as the OS's user interface. Because the OS controls the…
Q: Create a function myFactorial that will accept a positive integer and calculate the factorial. You…
A: Start Accept num from the user Check the input is not a valid integer if it is not valid integer do…
Q: By using Java, Give implementation of binary search tree (BST) using array, that displays the…
A: A binary search tree which refers to the one it is a rooted binary tree in which the nodes are…
Q: Which of the following regular expressions describes the language recognised by the a € a b none of…
A: Solution The given automaton mainly consists 5 tuples which are Finite Automata D=(Q,δ,Σ, F, q0) Q…
Q: nput: a) ManufacturerList.csv -- contains items listed by row. Each row contains item ID,…
A: The above code is a program that manages the inventory of an electronics store. It uses classes,…
Q: FS traversal of the graph in Figure 1 starting at r he alphabetical order. List the nodes in the…
A: Solution - In the given question, we have to do DFS and BFS traversal for the given graph.
Q: The Ubuntu Server Operating System is a server operating system that is based on Linux and is…
A: It is a system programme that manages the hardware and software of a computer system. This server…
Q: Processes outside of systems analysis may be described using structured English.
A: The term "structured programming approaches" refers to all of the methods that are defined by…
Q: In what ways did you hope your preliminary Internet investigation might help to improve the…
A: The method in which new ideas are conceived and information is produced has been profoundly impacted…
Q: #include #include #include using namespace std; int main() { string userItem;…
A: Answer: #include <iostream>#include <sstream>//#include using namespace std; int main()…
Q: Identify three commonly used protocols inside the company that are either not secure or may be…
A: Introduction A protocol, service, and port that raises security issues because there aren't any…
Q: Put T(true) or F (False) for each of the following statements. The PCON register is a…
A: Dear Student, The answer to your question is given below -
Q: Which of the following is NOT a type of non-traditional DBMS? NOSOL • In-memory • relational NewSQL
A: Your answer is given below with an explanation.
Q: Overloading a method is to provide more than one method with the same name but with different…
A: Dear Student, The answer to your question is given below -
Q: Explain DNS and OpenSSH and their importance in Linux
A: Introduction: The domain name system (abbreviated "DNS") is in charge of converting domain names…
Q: How serious are the issues plaguing the worldwide web of information?
A: A global information system is a technology or information system that tries to give all of the…
Q: The mpstat command can be used to display load averages in the last 1, 5, and 15 minutes. True…
A: Dear Student, The answer to your question is given below -
Q: ase write this in Python: // Step 1: Create an empty array of size 26 to store the frequencies…
A: Dear Student, The complete code with implementation and expected output is given below -
Q: Differences between smart watch, Pc, and uav/drone operating systems?
A: Operating system An operating system(OS) provides an interface between the computer user and the…
Q: Describe three problems with Data Analytics and use one to apply ethical theory.
A: Introduction Data analytics is essential for making decisions. This strengthens decision-making, ups…
Q: String.ParseInt(m); will convert the integer value of m to a String
A: Parse of a string: Here string can be changed to the specified format. No integer values are parsed…
Q: Is there a certain set of guidelines that the OS's microkernel follows? Where does this approach…
A: The microkernel operating system reduces the kernel to merely process communication and IO…
Q: Algorithm for Match in a pyramid tournament. in: set P of players in the pyramid structure; players…
A: Algorithm for Match in a pyramid tournament:
Q: Question 12 kan A problem Q is algorithmically solvable if there exists a Turning machine T for…
A: Dear Student, The answer to your question is given below -
Q: Write a VB program that reads the oil prices in a week, stores them in a one dimensional array, and…
A: The required Visual Basic code is as follows Imports System Module VBModule Sub Main()…
Q: In order to demonstrate your competence, you should define the various types of social networking…
A: Introduction: We undoubtedly know how to utilise similar virtual entertainment gadgets that we use…
Q: • E7.20 Define an Employee structure with a name and an Employee* pointer to the employee's manager.…
A: Answer: Algorithms: Step1: We have struct the Employee data as string and next as pointer Step2:…
Q: In more than sixty words, using clearly labeled illustrations, explain three (3) cutting-edge…
A: In this section, we'll focus on data set and server hardening as well as recommended practises for…
Q: ment the TNode and Tree classes. The TNode class will include a data item name of type string, which…
A: Dear Student, The source code, implementation and expected output of above question is given below -
Q: Write a Python program that asks a user to input expressions (e.g., 5+6) and saves Problem 2 them…
A: import rep='^[0-9]+[+-/*]{1}[0-9]+$'k=input("Enter the Expression : ")while(not(str(k)=="done")):…
Q: Write a function that takes as input a positive integer and returns true if it is prime and false…
A: 1) Below is C++ Program that write a function that takes as input a positive integer and returns…
Q: Question 39 What command allows you to print all of the global environment variables present within…
A: Introduction Every device on a network can be recognized by its IP address, that stands for Internet…
Q: Your city councilor wants you to help in gathering information about students that deserve the…
A: Solution: Given, collect are the student's SIDs, Age, Gender, and current CGPA. You are required…
Q: Please answer fast 1.The difference between forecasting and prediction. Please provide a…
A: According to bartleby guidelines we are supposed to answer only 1 question,so i have answered 1,…
Q: Write a C program that show the equivalent between ASCII value and Decimal value.
A: Initialise a loop that will iterate through all possible ASCII values (0-255). For each iteration of…
Q: Write a copy constructor for CarCounter that assigns origCarCounter.carCount to the constructed…
A: I give the code in C++ with inline comments and screenshots of the output and the code
Q: Please use Python
A: The Java program for the given problem is as follows: import java.util.*; import…
Q: Include a list of all the parts of an OS kernel and a brief description of what they do.
A: Kernel is an OS's core PC software. Since the OS has influence over the framework, the Kernel does…
Q: Create Binary Search Tree Using Following Elements 45,15,79,90,10,55,12,20,50,65 (insert) 90,79,45…
A: A binary search tree arranges the elements in some order. In BST, the value of left node has smaller…
Q: Where does the CAP theorem come from, and how does it function? What does this signify for NoSQL…
A: Answer The CAP theorem, also known as Brewer's Theorem, originated from computer scientist Eric…
This is Java
The current code for BstMaxHeap is printing names backwords. So please modify the code BstMaxHeap.java so it prints as the following:
The heap is not empty; it contains 9 entries.
The largest entry is Whitney
Removing entries in descending order:
Removing Whitney
Removing Regis
Removing Megan
Removing Matt
Removing Jim
Removing Jared
Removing Doug
Removing Brittany
Removing Brett
Step by step
Solved in 3 steps with 1 images
- java method : Write a method called prioritizeQueue to give priority for vaccination for elderly persons. The method is to be in a class called VaccinationQueue and has two parameters q1 and q2 type ArrayQueue. The q1 and q2 data are of type Integer. Assume that initially q1 is not empty and q2 is empty. The method will insert from q1 those elements towards the beginning of the queue (front) q2 whose data is greater than or equal to 45 and will insert those elements whose data is less than 45 and greater than or equal to 18 towards the end (rear) of q2. Any data item less than 18 of q1 will not be inserted in q2. It returns the number of elements added to q2. Class ArrayQueue and all its methods including iterator are available for use. You can also create temporary queues. You are not allowed to use arrays or any other data structure. Example: Before method call: front rear q1: 14 25 50 70 35 45 19 10 21…The implementation of a queue in an array, as given in this chapter, uses the variable count to determine whether the queue is empty or full. You can also use the variable count to return the number of elements in the queue. On the other hand, class linkedQueueType does not use such a variable to keep track of the number of elements in the queue. Redefine the class linkedQueueType by adding the variable count to keep track of the number of elements in the queue. Modify the definitions of the functions addQueue and deleteQueue as necessary. Add the function queueCount to return the number of elements in the queue. Also, write a program to test various operations of the class you defined.Min Heap of Candy — Add and Remove Using the provided code (Question04.java and Candyjava), write the add and remove methods for a min heap of Candy using an array implementation. Make sure to include all provided files in your project and write your solution in the file "Question04.java". This method should preserve the properties of a min hap, and the candies are compared based on their weight. This value can be accessed through its accessor. Solution Tests: • Does the solution compile? • Does the solution have your name in the comments? • Does the solution have a high-level solution description (150-300 words) in the comments? • Does the method preserve the properties of a Min Heap? • Does the output match the following? Testing the Add Method Candy Weight: 10.0, Candy Weight: 40.0, Candy Weight: 20.0, Candy Weight: 50.0, Candy Weight: 60.0, Candy Weight: 80.0, Candy Weight: 30.0, Candy Weight: 100.0, Candy Weight: 70.0, Candy Weight: 90.0, Testing the Remove Method Candy Weight:…
- Question 11 Write a method called changeQueue to be considered inside the ArrayQueue class and has one parameter item of type E. Your method will change the queue in such a way that if the the first element of the queue and the last element of the queue are equal, the first and last elements in the queue will be replaced with item, otherwise, do not do any change. Similarly, the same process is done for the second element in the queue and the element before the last in the queue and so on. Assume you have a non-empty queue with even number of elements. You are not allowed to call any method from the the ArrayQueue class. Do not use iterators. Method head: public void changeQueue(E item) Example1: Before run: front rear "this" queue: 10 29 2 25 10 Item1: 100 After run: front rear "this" queue: 100 29 100 100 5 100 Use the editor to format your answerProject Description: In this project you implement an ArrayStack ADT and use the stack for implementing the following methods: a) Reverse an array of Words: Accept an array of words as input parameter and return an array of words in reverse order. Use the method signature: public static String[] reverse Words (String[] wordList) Example Input: Bird Cat Dog Elephant Output: Elephant Dog Cat BirdJava - This project will allow you to compare & contrast different 4 sorting techniques, the last of which will be up to you to select. You will implement the following: Bubble Sort (pair-wise) Bubble Sort (list-wise) [This is the selection sort] Merge Sort Your choice (candidates are the heap, quick, shell, cocktail, bucket, or radix sorts) [These will require independent research) General rules: Structures can be static or dynamic You are not allowed to use built in methods that are direct or indirect requirements for this project – You cannot use ANY built in sorting functions - I/O (System.in/out *) are ok. All compare/swap/move methods must be your own. (You can use string compares) Your program will be sorting names – you need at least 100 unique names (you can use the 50 given in project #3) – read them into the program in a random fashion (i.e. not in any kind of alpha order). *The more names you have, the easier it is to see trends in speed. All sorts will be from…
- Project Description: In this project you implement an ArrayStack ADT and use the stack for implementing the following methods: a) Reverse an array of Words: Accept an array of words as input parameter and return an array of words in reverse order. Use the method signature: public static String[] reverseWords (String[] wordList) Example Input: Bird Cat Dog Elephant Output: Elephant Dog Cat BirdData Structure and algorithms ( in Java ) Please solve it urgent basis: Make a programe in Java with complete comments detail and attach outputs image: Question is inside the image also: a). Write a function to insert elements in the sorted manner in the linked list. This means that the elements of the list will always be in ascending order, whenever you insert the data. For example, After calling insert method with the given data your list should be as follows: Insert 50 List:- 50 Insert 40 List:- 40 50 Insert 25 List:- 25 40 50 Insert 35 List:- 25 35 40 50 Insert 40 List:- 25 35 40 40 50 Insert 70 List:- 25 35 40 50 70 b). Write a program…Complete ArrayStack.java, an array-based implementation o the Stack.java interface. Modify only the bodies of the following methods in the ArrayStack class: push pop top isEmpty isFull Nothing else should be modified in ArrayStack. Write the class ArrayStackTest to test your implementation. Print only the names of the tests and error messages. Give the test method meaningful names (e.g., emptyStackTest). Test push, pop, top, and isEmpty immediately after the stack has been instantiated. Push an element on an empty stack. Test pop, top, and isEmpty. Instantiate a stack with initialCapacity of 1. Push two elements. Check capacity. Other tests you deem necessary.
- Write a program and fill a queue with random numbers between 0 and 100. The size of thequeue is assumed to be 15. After filling the array with random numbers, display the elements in the queue and remove the elements of the queue and store these numbers according to the following criteria.If the number in the queue is less than 50, remove it from the queue and store it inside queue 2.Else, remove the number and store these values inside queue 3.Display all three queues on the screen.Develop a class ResizingArrayQueueOfStrings that implements the queueabstraction with a fixed-size array, and then extend your implementation to use arrayresizing to remove the size restriction.Develop a class ResizingArrayQueueOfStrings that implements the queueabstraction with a fixed-size array, and then extend your implementation to use arrayresizing to remove the size restriction.PLEASE TYPE ONLY*** JAVA PROGRAMMING Task: a program called ArrayList_Practice. In this program, please do the following operations. Complete a method called RedundantCharacterMatch(ArrayList<Character> YourFirstName): the parameter of this method is an ArrayList<Character> whose elements are the characters in your first name (they should be in the order appear in your first name, e.g., if your first name is bob, then the ArrayList<Char> includes ‘b’, ‘o’, ‘b’.). The method will check whether there exists duplicate characters in your name and return the index of those duplicate characters. For example, when using bob as first name, it will return b: 0, 2. Create ArrayList<Character> NameExample. All the characters of your first name will appear twice in this ArrayList. For example, if your first name is bob, then NameExample will include the following element {b,o,b,b,o,b}. Then, please use NameExample as parameter for the method RedundantCharacterMatch(). If…