1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
atroni [7]
3 years ago
12

Program your own file lab7.cpp in which your main() function will test the new data structure. The main() function, Declares an

instance of BinarySearchTree (short: BST) suitable to hold integer values. Prompts user to enter a random sequence of integer values, inserts these values into the data structure (the entered values should NOT be in sorted order). Calls the print BAR() member function to print out the values of the BST structure. Prompts user to enter a random sequence of integer values, remove these values from your BST. Print out the reduced BST. Exercise 3: Write a function printRange that takes as input a binary search tree t and two keys, k1 and k2, which are ordered so that k1 < k2, and print all elements x in the tree such that k1 <= x <= k2. Add the following member function in your BinarySearchTree class template.
Computers and Technology
1 answer:
Stella [2.4K]3 years ago
3 0
Is this a question or just something up here just to be here
You might be interested in
What is computer hardware / software​
Pavel [41]

Answer: <u>Computer hardware is any physical device used in or with your machine, like for example, a mouse, or a keyboard.</u> Computer software is a collection of programming code installed on your computer's hard drive it can process billions of data and inputs through this.

Hope this helps!

5 0
3 years ago
The music is the soul who says this
Crazy boy [7]

Question:the music is the soul who says this

Answer: Arthur Schopenhauer

Explanation: he says music is the language of feeling and of passion

question answered by

(jacemorris04)

4 0
3 years ago
Write a program with a main method that asks the user to enter an array of 10 integers. Your main method then calls each of the
Kay [80]

Answer:

The remaining part of the question is given as follows:

printReverse - a void method that reverses the elements of the array and prints out all the elements in one line separated by commas (see sample output below).

getLargest - an int method that returns the largest value in the array.

computeTwice- a method that returns an array of int which contains 2 times of all the numbers in the array (see the sample output below).

Explanation:

// Scanner class is imported to allow the program receive

// user input

import java.util.Scanner;

// Arrays class is imported to allow the program display the array

// in a pretty way

import java.util.Arrays;

//The class definition

public class Solution {

   // main method is defined which signify beginning of program

  // execution

   public static void main(String[ ] args) {

       // an array is initialized with a size of 10

       int[] array =new int[10];

       // Scanner object scan is defined

       Scanner scan =new Scanner(System.in);

       // A loop is initiated to receive 10 user input to fill the array

       for(int i=0; i < 10; i++){

           System.out.print("Please enter number: ");

           array[i]=scan.nextInt();

       }

       

       // A blank line is print

       System.out.println();

       // printReverse method is called with the received array as

      // argument

       printReverse(array);

       // A blank line is print

       System.out.println();

       // The largest number is printed

       System.out.println("The largest number is: " + getLargest(array));

       // computeTwice method is called to display the array after

      // multiplying each element by 2

       computeTwice(array);

       System.out.println( "The values of the computed twice array is: " );

       // Arrays class is used to print the array in form of a string

      // not object

       System.out.println(Arrays.toString(array));

   }

   

   //printReverse method declared with inputArray as parameter.

   // It has no return type

   public static void printReverse(int[] inputArray){

       System.out.print("Here is the arrray in reverse order: ");

       // A loop goes through the array starting from the end

       // and display each element

       for(int i = (inputArray.length - 1); i >= 0; i--){

           if(i == 0){

               // If the last element, do not append comma

               System.out.print(inputArray[i]);

           } else {

               // If not the last element, do append a comma

               System.out.print(inputArray[i] + ", ");

           }

       }

   }

   

   // getLargest method is declared with inputArray as parameter

   //  it compare each element in the array and return the largest

   public static int getLargest(int[] inputArray){

       // The first element is assumed to be the largest before the

      // loop begin

       int max = inputArray[0];

       for(int i = 1; i < inputArray.length; i++){

           if (inputArray[i] > max){

               max = inputArray[i];

           }

       }

       return max;

   }

   

   // computeTwice is declared with inputArray as parameter

   // it loop through the array and multiply each element by 2

   // it then return a modified array

   public static int[] computeTwice(int[] inputArray){

       for(int i = 0; i < inputArray.length; i++){

           inputArray[i] *= 2;

       }

       return inputArray;

   }

}

8 0
3 years ago
A technician is performing Windows preventative maintenance tasks on all computers in the organization. She wants a way to creat
Sedaia [141]

Answer:mmc.exe

Explanation:

mmc.exe is used to manage Windows network with a variety of snap-ins(administrative tools that can be added to the console and used to manage various aspects of your network).

The technician will.be able to use mmc.exe to to create a custom console containing only the tools she regularly launches and then distribute this custom console to each computer.

3 0
4 years ago
Fill in the blank: when you execute code in the source editor, the code automatically also appears in the___ a. Files tab b. Plo
trapecia [35]

When you execute the code in source editor, then the code automatically also appears in the <u>R console</u>. Hence, option 'C' is the right answer.

<h3>What is source editor?</h3>

A text editor programme called a source-code editor can be used to edit the source code of computer programmes. It could be a standalone application, one that is incorporated into an IDE, or a web browser.

A source-code editor is a fundamental piece of programming hardware because writing and editing source code is a fundamental task for programmers.

A few of the features that source-code editors have are brace matching functionality, autocomplete, syntax highlighting, and indentation. These features are designed to make typing source code simpler and faster. These editors also provide a simple way for users to start a compiler, interpreter, debuger, or other software-development-related programme.

Learn more about source code

brainly.com/question/29661963

#SPJ1

5 0
1 year ago
Other questions:
  • What type of attack intercepts communication between parties to steal or manipulate the data?
    13·1 answer
  • A method countDigits(int num) of class Digits returns the remainder when the input argument num(num &gt; 0) is divided by the nu
    10·1 answer
  • Which device or appliance emits radio waves
    7·1 answer
  • What are the two types of computer keyboards and how are they different?
    6·2 answers
  • URGENT!!! Steve wants to change shooting and exposure settings while on his photo shoot. Which camera part will allow him to do
    12·2 answers
  • Lucia is using the American Psychological Association (APA) style guidelines to writer her research paper. What is her most like
    5·2 answers
  • What is bespoke software???​
    9·2 answers
  • If you wanted to divide an integer variable by 2, which of the following lines of code would you use? total = int + 2 total = in
    6·1 answer
  • I am making a project i have to advertise a product i picked a futureistic car
    10·1 answer
  • What year was internet inverted
    13·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!