Jump to content

contiguidae physical and chaining

- - - - -

This topic has been archived. This means that you cannot reply to this topic.
4 replies to this topic

#1
Apprentice123

Apprentice123

    Programming Expert

  • Members
  • PipPipPipPipPipPip
  • 430 posts
1. its nodes at random positions in memory
2. be difficult to transfer
3. always have the link fields in their nodes
4. be difficult to operate in terms of insertions and deletions
5. be operated only by the update of fields in pointer
6. be stored in computer memory
7. obey conventions implied of recovery

a) The structure represented by physical contiguity is characterized by (correct list of options)
My solution => 3, 5 and 6

b) The structure represented by chaining is characterized by
My solution => 3, 4, 6 and 7

2) (T)True or (F)Fake
( ) a disadvantage is that the chain tends to complicate the design of complex structures
( ) an advantage of physical proximity is that expansions and compaction can be adopted to make insertions and withdrawals
( ) the definition of an Abstract Data Type should be careful that the operations produce results only as objects of a type definition

My solution
(F), (T), (T)

#2
WingedPanther

WingedPanther

    A spammer's worst nightmare

  • Moderators
  • 16,831 posts
Before responding, can you clarify:

physically contiguous refers to arrays?
chaining refers to things like linked lists?
Programming is a branch of mathematics.
My CodeCall Blog | My Personal Blog

#3
Apprentice123

Apprentice123

    Programming Expert

  • Members
  • PipPipPipPipPipPip
  • 430 posts

WingedPanther said:

Before responding, can you clarify:

physically contiguous refers to arrays?
chaining refers to things like linked lists?

Yes Exactly

#4
WingedPanther

WingedPanther

    A spammer's worst nightmare

  • Moderators
  • 16,831 posts

Apprentice123 said:

1. its nodes at random positions in memory
2. be difficult to transfer
3. always have the link fields in their nodes
4. be difficult to operate in terms of insertions and deletions
5. be operated only by the update of fields in pointer
6. be stored in computer memory
7. obey conventions implied of recovery

a) The structure represented by physical contiguity is characterized by (correct list of options)
My solution => 3, 5 and 6
arrays involve a lot of copying, so 2 could be here.
3 doesn't make sense here (no pointers).
insertions are a pain with arrays, so 4 should be here.
5 doesn't make sense here (no pointers)
I don't know what 7 is referring to

Apprentice123 said:

b) The structure represented by chaining is characterized by
My solution => 3, 4, 6 and 7
Linked lists use pointers, so 1 has to be here.
4 wouldn't be here, it's just a matter of updating a couple of pointers to insert/delete.
5 would go here (uses pointers)
I still don't know what 7 is refferring to.

Apprentice123 said:


2) (T)True or (F)Fake
( ) a disadvantage is that the chain tends to complicate the design of complex structures
( ) an advantage of physical proximity is that expansions and compaction can be adopted to make insertions and withdrawals
( ) the definition of an Abstract Data Type should be careful that the operations produce results only as objects of a type definition

My solution
(F), (T), (T)
My solution:
F: linked lists aren't that complicated
F: arrays are a PAIN to do inserts on
T
Programming is a branch of mathematics.
My CodeCall Blog | My Personal Blog

#5
Apprentice123

Apprentice123

    Programming Expert

  • Members
  • PipPipPipPipPipPip
  • 430 posts
Thanks