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
Luda [366]
2 years ago
15

Help to how to write pseudo code to insert a new node to Binary Search Tree. Using C++.

Computers and Technology
1 answer:
dimulka [17.4K]2 years ago
4 0

Answer:

Let the function be Node* ins(Node *root,int k)

if root node is NULL then return new node with data equal to k.

If the k <root->data

root->left=ins(root->left,k);

else if k >root->data

root->right =ins(root->right,k);

At last return root.

Explanation:

Node is always inserted at the at the leaf node.We will search k in the tree if we hit a the leaf node the new node is inserted as the child of the leaf node.

You might be interested in
Before entering a loop, the first input, or ____, is retrieved.
Virty [35]

Loop is a control structure that causes a statement or group of statements to repeat.Before entering a loop, the first input, or the accumulator where the total will be kept is retrieved to an initial value, usually zero.

3 0
3 years ago
How does a cloud-first strategy differ from other approaches to cloud?
Irina18 [472]

Cloud-first strategy differ from other approaches as It keeps all the services performed by legacy systems while moving to the Cloud in a staggered approach.

<h3>What is a cloud first strategy?</h3>

The change of cloud computing has brought about  “cloud-first” strategy.

This  is known to be a way to computing that tells that a firm should look first to cloud solutions when creating new processes or taking in old processes before taking in non-cloud-based solutions.

Note that Cloud-first strategy differ from other approaches as It keeps all the services performed by legacy systems while moving to the Cloud in a staggered approach.

See options below

it enables an organization to completely move to the cloud without infrastructure or support requirement

it keeps all the services performed by legacy systems while moving to the cloud in a staggered approach.

it partners technology with multiple other disciplines for comprehensive business transformation.

it uses artificial intelligence to automate all business processes and completely eliminate human error.

Learn more about cloud from

brainly.com/question/19057393

#SPJ1

6 0
2 years ago
Assume you're using a three button mouse. to access shortcut menus, you would
Likurg_2 [28]
<span>Normally you would click the right hand/secondary mouse button but you may configure any of the buttons to work within the Keyboard and Mouse section of System Preferences.
Hope this helps:)</span>
6 0
3 years ago
Read 2 more answers
What is another word for microchips operating systems input methods and everything in between?
lord [1]
The answer is computer. A computer is made up of microchips (CPU and GPU), an operation system (macOS or Windows), input methods (keyboard and mouse), and other parts.
7 0
3 years ago
JAVA Code:
Burka [1]
Dear ,you should ask it on stackoverflow and geekforgeelks , not here
6 0
3 years ago
Other questions:
  • When planning your educational and career path, it makes sense to consider where you want to work and what type of work you want
    14·1 answer
  • In general terms, a program that is broken into smaller units of code such as methods, is known as a ________
    6·1 answer
  • You can create a database using one of the many templates available or by creating a new ______ database.
    9·1 answer
  • Hat are three machines or devices that depend on gravity to work?
    5·1 answer
  • Company that offers Internet access to individuals and businesses. This device connects two or more networks and directs the flo
    11·1 answer
  • There are many modes of remote visual communication. which is the most common mode
    5·1 answer
  • Why do you think that so many of these sources have similar names?
    9·1 answer
  • Of the following field which would be the most appropriate for the primary key in a customer information table?
    5·1 answer
  • The following pieces are known as (image shown above)
    15·2 answers
  • How does the quantity of data affect the accuracy of an experiment?
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!