Already have an account? Get multiple benefits of using own account!
Login in your account..!
Remember me
Don't have an account? Create your account in less than a minutes,
Forgot password? how can I recover my password now!
Enter right registered email to receive password!
Q. Write down an algorithm to test whether a Binary Tree is a Binary Search Tree.
Ans.
The algorithm to check whether a Binary tree is as Binary Search tree is as
follows:
bstree(*tree)
{
while((tree->left !=null)&& (tree->right !=null))
if(tree->left < tree->root)
bstree(tree->left);
else return(1);
if(tree->right > tree->root)
bstree(tree->right);
}
return(0);
Best Case: If the list is sorted already then A[i] T (n) = c1n + c2 (n -1) + c3(n -1) + c4 (n -1) = O (n), which indicates that the time complexity is linear. Worst Case:
INSERT FUNCTION /*prototypes of insert & find functions */ list * insert_list(list *); list * find(list *, int); /*definition of anyinsert function */ list * inser
what are the applications of multikey file organization?
what''s queue ?
Technique for direct search is Hashing is the used for direct search.
Explain in brief about the Container An entity which holds finitely many other entities. Just as containers such as boxes, baskets, bags, pails, cans, drawers, and so for
Define min-heap A min-heap is a complete binary tree in which each element is less than or equal to its children. All the principal properties of heaps remain valid for min-hea
Q1. Define a sparse matrix. Explain different types of sparse matrices? Evaluate the method to calculate address of any element a jk of a matrix stored in memory. Q2. A linear
The time needed to delete a node x from a doubly linked list having n nodes is O (1)
what is tree
Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!
whatsapp: +91-977-207-8620
Phone: +91-977-207-8620
Email: [email protected]
All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd