Guest User

Untitled

a guest
Jan 17th, 2018
89
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.49 KB | None | 0 0
  1. INITIALIZE-F (k)
  2. F=ARRAY[1,k] of INT
  3. for i = 1 to k
  4. F[i]=NIL
  5. i=0
  6.  
  7. MAKE-SET(x)
  8. Si=LINKED-LIST of INT
  9. y=NewNode(x)
  10. Si.head=y
  11. Si.tail = y
  12. y.prev=NIL
  13. y.next = NIL
  14. F[i]=Si.head
  15. i=i+1
  16.  
  17. DISJOINT-UNION(Si,Sj)
  18. A.tail.next=B.head
  19. B.head.prev=A.tail
  20. B.head=NIL
  21. B.tail = NIL
  22. REPORT(Si)
  23. x=A.head
  24. while x!=NIL
  25. PRINT x.data
  26. x=x.next
Add Comment
Please, Sign In to add comment