Question

From the following numbers... Please follow steps 1-3 for these integers ~ 14,40,26,32 ,12,45,28,9,8,16 remove the...

From the following numbers...

Please follow steps 1-3 for these integers ~ 14,40,26,32 ,12,45,28,9,8,16

remove the numbers below individual which show the fusions and correction of them

~ 26, 9, 16

1. Make a 2-3 Tree so that... (all steps and the removal  

2. You can make a 2-3-4 Tree (all steps and the removal  

3.so finally you can make Red-Black Tree (showing red and black lines for the node that are red/black)(all steps and the removal  

Do Not Use Tree Calculator it should SHOW ALL STEPS FOR ALL OF THEM I will share and upvote, THANKS!

0 0
Add a comment Improve this question Transcribed image text
Answer #1


ANSWER m Given numbeu 14 ,40, 26, 32 , 12 , 45, 28, 9, aue 8, 16 Step 1 Make 2-3 Taee intich thee data stnctmu 2-3 Tree M- la

32 Value goes to child as ght Tnest 32 22 26 hue chan auadingly becaur 3 2 L4o Tnent 12 as 2 26 26 3240 14 12 clild sight Trs

2S Insut ni ddle child 26|4ロ 2832 214 45 Frseut cua tana left child 26 40 apit it) 28 32 45 aain oiflaro at top node am 28 32

Tngeot 26 So it gees child eft -ight 451 4 6232 final 2-3 Tree 26,9, 16 need to amove Non Le Rigiut subtree gorna jemain same

Right subtre qowna Aeman same 6ft Subtree gmna change laiest ft subtree replie 6 vaine [4 40 2832 45 undeflow No oft Subtree

Stp 2: 2-3-4 Tre - A 2-node has inteinal data element and h one has tw child nodes A -node hau tuo data eiements , and if Lnt

Tneat 12 32 14 Busut 4S 20 45 1214 32 Tnseut 28 24 26 2 3240 5 (ovesfla) 14 40 45 28 121 1니 Ssput 26 32 40145 28 12 14 Inseut

2632 41214 28 pweuf low split 26/32 4045 28 12 14 Tnseut 6 92632 401451 28 2 1416 final Tree qamd 26 is Delet 26: ubtree betw

delete deteti (4) hen Maplace undeyflono mallestvalu d iyht Subtree Huis Condsti on ondi tu Aeplaiad y wil be | 6 32. 445 28

Ved -Bla ck Stap Tree /C A node 2 The ot and leaves (NIL) are black node i^^ed -hm i childsen are black 3. Df a a node to des

Pnset 32 3 2 26 E14 3 2 32 net 2 26

Tuset 45 (1D 45 3 2 Tnnt 28 26. 45 28 28 Singe 28 28

push Llack |2 45 28 28 Tnseut l6 26 4 45 14 Rad Black Tree inal

tHighest valu in oplaces Deliti 2 &ubtree 26 40 45 28 Delet and make g as black Deleti 9 28

Delit 16 Replace and 6with lagest valu ic, 14 make 12 4 40 45 22 28 fnal Rad Black Tiee after deletion

Add a comment
Know the answer?
Add Answer to:
From the following numbers... Please follow steps 1-3 for these integers ~ 14,40,26,32 ,12,45,28,9,8,16 remove the...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • Tree & Hash Table & Heap Use the following integer keys 73, 58, 91, 42, 60, 130, 64, 87 to perform the followings: a) Binary Search Tree - Draw a binary search tree - Retrieve the integers ke...

    Tree & Hash Table & Heap Use the following integer keys 73, 58, 91, 42, 60, 130, 64, 87 to perform the followings: a) Binary Search Tree - Draw a binary search tree - Retrieve the integers keys in post-order - Retrieve the integers keys in pre-order - Draw a binary search tree after node 58 is deleted b) Create a Hash Table using the methods described below. Show the final array after all integer keys are inserted. Assumes that...

  • (a) On an initially empty red-black tree, perform the following operations in this order: insert(1), insert(3),...

    (a) On an initially empty red-black tree, perform the following operations in this order: insert(1), insert(3), insert(5), insert(6), insert(7), delete(1) Show all the intermediate steps of your work (b) We can get another sorting algorithm by first inserting all the keys into a red-black tree, and then performing an in-order traversal of the tree. What's the time complexity of this algorithm? (As always, use O or Θ notation.)

  • Please I need Solution in an hour show the steps for each algorthim C++ 1-Sort by...

    Please I need Solution in an hour show the steps for each algorthim C++ 1-Sort by steps in ascending way by Quick sort (3-way-partitioning) (ZAHRLI SME TJD BUNK) 2-Sort by steps ascending way by heap sort and heap construction and tree (ZAHRL I SME TJD BUNK). 3. Create the binary search tree( BST )from the 16 characters mentioned above and in steps, then delete the min and explain the result in steps. 4. Create a search tree 2-3 of the...

  • 3. Given integers from 1 to 8. If five numbers are taken, they can it is...

    3. Given integers from 1 to 8. If five numbers are taken, they can it is certain that two of them number 9. Prove or deny.

  • Tree & Hash Table & Heap Use the following integer keys 73, 58, 91, 42, 60,...

    Tree & Hash Table & Heap Use the following integer keys 73, 58, 91, 42, 60, 130, 64, 87 to perform the followings: a) Binary Search Tree - Draw a binary search tree - Retrieve the integers keys in post-order - Retrieve the integers keys in pre-order - Draw a binary search tree after node 58 is deleted b) Create a Hash Table using the methods described below. Show the final array after all integer keys are inserted. Assumes that...

  • Red black trees Perform insertions of the following keys, 4, 7, 12, 15, 3, 5, 14,...

    Red black trees Perform insertions of the following keys, 4, 7, 12, 15, 3, 5, 14, 18, 16, 17 (left to right) into a redblack tree, then, perform deletions of keys 3, 12, 17, under the properties as provided below. • Root propoerty: the root is black. • External propoerty: every leaf is black. • Internal propoerty: the children of a red node are black. • Depth propoerty: all the leaves have the same black depth. Note that insertions have...

  • please make a pretty JAVA GUI for this code this is RED BLACK TREE and i...

    please make a pretty JAVA GUI for this code this is RED BLACK TREE and i Finished code already jus need a JAVA GUI for this code ... if poosible make it pretty to look thanks and please make own GUI code base on my code thanks ex: (GUI only have to show RBTree) ---------------------------------------- RBTree.java import java.util.Stack; public class RBTree{    private Node current;    private Node parent;    private Node grandparent;    private Node header;    private Node...

  • Show steps. Please. 3. Design a data structure D that can store integers. The data structure...

    Show steps. Please. 3. Design a data structure D that can store integers. The data structure should be ale to store nent can appear multiple times. The da the following operations in O(log n) time, where n is the number of distinct integers stored in D . add(x): Adds/inserts integer a into D. Even if belongs to D, z should still be added .frequencyx) Nuber of times r appears in D search(x): Returns true if is in D order (y):...

  • in C++ please 1- Write the priority queue code – include insertion and remove operations. Given...

    in C++ please 1- Write the priority queue code – include insertion and remove operations. Given the following values – test your program. Use max-heap. 8, 17, 4, 99, 3, 6, 88, 34, 65 2- Sort the numbers: 8, 17, 4, 99, 3, 6, 88, 34, 65 using heap-sort and show the steps - you may write it on a paper and take a picture and include it here. Show all steps. 3- Write the heap-sort code and test the...

  • prove the product of 4 consecutive integers is always divisible by 24 using the principles of math induction

    prove the product of 4 consecutive integers is always divisible by 24 using the principles of math induction. Could anyone help me on this one? Thanks in advance!Sure For induction we want to prove some statement P for all the integers. We need: P(1) to be true (or some base case) If P(k) => P(k+1) If the statement's truth for some integer k implies the truth for the next integer, then P is true for all the integers. Look at...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT