Follow

Translate

Monday, March 21, 2016

Inserting after a Given Node



1.         [OVERFLOW?]  If AVAIL = NULL,  then:  Write:  OVERFLOW, and Exit.

2.      [Remove first node from AVAIL list.]

3.   Set INFO[NEW] : = ITEM.    [Copies new data into new node.]

4.  If LOC = NULL, then:   [Insert as first node.]
              Set LINK[NEW] : = START and START : = NEW.
Else:     [Insert after node with location LOC.]
             Set LINK[NEW] : = LINK[LOC] and LINK[LOC] : = NEW.
[End of If structure]

5.Exit.

If You want to learn about the technology, computer science & engineering, web programming, freelancing, earning please click here :CSE SOLVE

Related Posts:

  • Solve Math problem By Using Linear Arrays Solve Math problem By Using Linear Arrays: 4.1  Consider the linear arrays AAA(5:50), BBB(-5:10) and CCC(18). (a) Find the number of elements in each array. (b) Suppose Base(AAA) = 300 and W = 4 words per memory cel… Read More
  • Example Using the bubble sort algorithm Using the bubble sort algorithm, Algorithm 4.4, find the number C of comparisons and the number D of interchanges which alphabetize the n = 6 letters in PEOPLE. The sequence of pairs of letters which are compared in … Read More
  • Number Sorted Of Bubble Sort Suppose the following numbers are stored in an array A:                             … Read More
  • (Matrix Multiplication) MATMUL(A, B, C, M, P, N) (Matrix Multiplication) MATMUL(A, B, C, M, P, N) Le A be an M * P matrix array, and let B be a P * N matrix array. This algorithm stores the product of A and B in an M * N matix array C. 1.  Repeat Steps 2 to 4 for I… Read More
  • Deleting From a Linear Array Algorithm:  (Deleting From a Linear Array)  DELETE (LA, N, K, ITEM) Here LA is a linear array with N elements and K is a positive integer such that K < N. This algorithms Deletes… Read More

0 comments:

Post a Comment