arrays - Memory space consumption -


is there situation memory space taken linked list pointers more memory consumed array same problem if problem can solved both structures?

a linked list dynamically sized data, inserts , removes. typically on heap. comparing array mean array uses strategy being oversized unused entries inserts, , being reallocated if arrays threatens overflow.

so depends on actual array strategy , behavior of program, knowledge of it.

however every entry actual data needs space too, maybe pointer , allocated object. @ linked-list overhead form of indexing, in database. memory more or less irrelevant.

one should aware, instance linked list of booleans not clever.


Comments

Popular posts from this blog

java - Oracle EBS .ClassNotFoundException: oracle.apps.fnd.formsClient.FormsLauncher.class ERROR -

c# - how to use buttonedit in devexpress gridcontrol -

nvd3.js - angularjs-nvd3-directives setting color in legend as well as in chart elements -