answersLogoWhite

0

How do you copy only structure and not data?

Updated: 8/18/2019
User Avatar

Wiki User

8y ago

Best Answer

To copy a structure you simply allocate the amount of memory required to store the structure. For simple data structures like arrays that's all you need to do (leaving the memory uninitialised or set to some default value such as zero). But for complex structures like lists, trees and graphs, you need to recreate the links between the nodes within the allocated memory. If the original structure is not allocated in contiguous memory, this can be more trouble than it is actually worth. A simpler approach would be to rebuild the structure one node at a time, using the node's default value for the data. This can be simplified further by separating the data from the structure, so that the structure simply refers to the data rather than stores the data.

User Avatar

Wiki User

8y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: How do you copy only structure and not data?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

Are there any limitations to the exchange process between Excel and other Microsoft applications?

There would be some. For example if you copy data from Excel into Word, only values will come through, not the underlying formulas.There would be some. For example if you copy data from Excel into Word, only values will come through, not the underlying formulas.There would be some. For example if you copy data from Excel into Word, only values will come through, not the underlying formulas.There would be some. For example if you copy data from Excel into Word, only values will come through, not the underlying formulas.There would be some. For example if you copy data from Excel into Word, only values will come through, not the underlying formulas.There would be some. For example if you copy data from Excel into Word, only values will come through, not the underlying formulas.There would be some. For example if you copy data from Excel into Word, only values will come through, not the underlying formulas.There would be some. For example if you copy data from Excel into Word, only values will come through, not the underlying formulas.There would be some. For example if you copy data from Excel into Word, only values will come through, not the underlying formulas.There would be some. For example if you copy data from Excel into Word, only values will come through, not the underlying formulas.There would be some. For example if you copy data from Excel into Word, only values will come through, not the underlying formulas.


Why are the cells or range of cells being copied also called source area?

It is where the copy action is getting its data from, so it is the source of the data. So it can be referred to as the source area or the copy area.It is where the copy action is getting its data from, so it is the source of the data. So it can be referred to as the source area or the copy area.It is where the copy action is getting its data from, so it is the source of the data. So it can be referred to as the source area or the copy area.It is where the copy action is getting its data from, so it is the source of the data. So it can be referred to as the source area or the copy area.It is where the copy action is getting its data from, so it is the source of the data. So it can be referred to as the source area or the copy area.It is where the copy action is getting its data from, so it is the source of the data. So it can be referred to as the source area or the copy area.It is where the copy action is getting its data from, so it is the source of the data. So it can be referred to as the source area or the copy area.It is where the copy action is getting its data from, so it is the source of the data. So it can be referred to as the source area or the copy area.It is where the copy action is getting its data from, so it is the source of the data. So it can be referred to as the source area or the copy area.It is where the copy action is getting its data from, so it is the source of the data. So it can be referred to as the source area or the copy area.It is where the copy action is getting its data from, so it is the source of the data. So it can be referred to as the source area or the copy area.


What are the subject-matters of data structure?

types of data structure types of data structure


When you copy data and paste in excel sheet it pasting only formulas not the data how can I copy the data when the content is formula made?

Use the Paste Special facility. From there you can then choose to paste the values, rather than the formulas.


When data is lost the only way to recover it may be from a backup copy?

True


How do you amend a data structure?

How do you amend a data structure?


What is difference between Deep copy and shallow copy in iphone?

Shallow copy is duplicate little as possible. because of it copy one object to another object. it copy only structure not elements . Deep copy means Duplicate everything. it will be copy structure as well as elements; e.g :- char A*={'a','b','c'}; char B*={'x','y','z'}; B=A;


How do you copy things?

Go to the settings and then tap "Data Management". Next, Tap the soft-ware you want to copy. Tap "Copy" and your done. This only works in DSi


Wt is the different between structure and class?

A structure is a different from a class in the sense that a class can represent data elements as well as their associated functions whereas a structure can represent only data elements,, not their associated functions.


How do you prevent data duplication?

Data deduplication is the method by which you can prevent data duplication. Data deduplication is a specialized data compression technique for eliminating coarse-grained redundant data, typically to improve storage utilization. In the deduplication process, duplicate data is deleted, leaving only one copy of the data to be stored, along with references to the unique copy of data. Deduplication is able to reduce the required storage capacity since only the unique data is stored.


What is the difference between allocation and search data structure?

difference between serch data structure and allocation data structure


What is homogeneous data structure?

collection of dissimilar type of data is called non homogeneous data structure as for example structure .