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!
Write an algorithm to count number of nodes in the circular linked list.
Ans.
Counting No of Nodes in Circular List
Let list be a circular header list in memory. This algorithm traverse and counts number of nodes in a LIST.
0. set COUNT: = 0
1. Set PTR: = LINK [START]. {Initializes the
pointer PTR}
2. Repeat steps 3, 4, 5 while PTR = START;
3. COUNT = COUNT + 1
4. Set PTR = LINK [PTR]. [PTR now points to next
node]
[End of step 2 loop]
5. Exit
A striking application of DFS is determine a strongly connected component of a graph. Definition: For graph G = (V, E) , where V refer to the set of vertices and E refer to the
As part of an experiment, a school measured heights (in metres) of all its 500 students. Write an algorithm, using a flowchart that inputs the heights of all 500 students and ou
How will you represent a max-heap sequentially? Max heap, also known as the descending heap, of size n is an almost complete binary tree of n nodes such that the content of eve
Post order traversal: The children of node are visited before the node itself; the root is visited last. Each node is visited after its descendents are visited. Algorithm fo
Definition of Algorithm Algorithm must have the following five characteristic features: 1. Input 2. Output 3. Definiteness 4. Effectiveness 5
Q. Explain quick sort? Sort the given array using quick sort method. 24 56 47 35 10 90 82 31
File organisation might be described as a method of storing records in file. Also, the subsequent implications approaching these records can be accessed. Given are the factors invo
Let a be a well-formed formula. Let c be the number of binary logical operators in a. (Recall that ?, ?, ?, and ? are the binary logical operators). Let s be the number of proposit
Which data structure is required to change infix notation to postfix notation? Stack function is used to change infix notation to postfix notatio n
How branching takes place in Instruction pipeline. Explain with suitable examples
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