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 an algorithm that counts number of nodes in a linked list.
Ans.
Algorithm to Count No. of Nodes in Linked List
COUNT (INFO, LINK, START, NUM)
1. Set NUM: = 0 [initializes counter]
2. Set PTR=START [ initializes pointer]
3. Repeat steps 4 & 5 while PTR! = NULL
4. Set NUM:= NUM + 1 [ increases NUM by 1]
5. Set PTR: =LINK [PTR] . [updates pointer to point to next node]
[End of step 3 loop]
6. Return
how to write a code for for a company , for calculate the salary pay
Q. What is the need of using asymptotic notation in the study of algorithm? Describe the commonly used asymptotic notations and also give their significance.
An algorithm is a sequence of steps to solve a problem; there may be more than one algorithm to solve a problem. The choice of a particular algorithm depends upon following cons
important points on asymptotic notation to remember
lower triangular matrix and upper triangular matrix
Write an algorithm for binary search. Algorithm for Binary Search 1. if (low> high) 2. return (-1) 3. Mid = (low + high)/2 4. if ( X = = a[mid]) 5. return (mid); 6.
Instructions : You have to design a doubly linked list container. The necessary classes and their declarations are given below The main() function for testing the yo
Q. By making use of stacks, write an algorithm to determine whether the infix expression has balanced parenthesis or not.
Q. Give the algorithm for the selection sort. Describe the behaviours of selection sort when the input given is already sorted.
Before programming a problem solution those employees a stack, we have to decide how to represent a stack by using the data structures which exist in our programming language. Stac
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