A municipality stored details about every house in its pervi
A municipality stored details about every house in its perview as a ‘structure'. each containing a large number of details. These are to be sorted. The best approach is
A municipality stored details about every house in its perview as a ‘structure'. each containing a large number of details. These are to be sorted. The best approach is
Akilesh Kharvi ? Dec 8 '2016 at 22:3
Answer: store pointers to them in an array and sort the array
Explanation:
In general, an array of pointers can be used to point to an array of data items with each element of the pointer array pointing to an element of the data array. Data items can be accessed either directly in the data array, or indirectly by dereferencing the elements of the pointer array. The advantage of a pointer array is that the pointers can be reordered in any manner without moving the data items.
For example, the pointer array can be reordered so that the successive elements of the pointer array point to data items in sorted order without moving the data items. Reordering pointers is relatively fast compared to reordering large data items such as data records or strings. This approach saves a lot of time, with the additional advantage that the data items remain available in the original order.
The height of a binary tree is defined as the maximum number of edges in any path from the root to the leaf. The maximum number of nodes in any binary tree of height h is
Akilesh Kharvi ? Dec 8 '2016 at 21:59
Answer: \(2^{h+1}-1\)
Explanation:
The number of nodes in a binary tree of height h is at least h + 1, and at most \(2^{h+1}-1\) here h is the depth of the tree.
reference: http://en.wikipedia.org/wiki/Binary_tree#Properties_of_binary_trees
Computer Organization Architecture, Operating System, PGCET CSE Exam (Karnataka) 2011, Solved, Technical Aptitude
The principle of cache memory is primarily based on
Akilesh Kharvi ? Dec 8 '2016 at 21:57
Answer:the principle of locality of reference
Explanation:
principle of cache memory primarily based on
Cache memory is a specially designed faster access but it has smaller memory area,so it is generally used to keep recently referenced data and data near recently referenced data.
When a program executes on a computer, most of the memory references are not made uniformly to a small number of locations. Here the Locality of the reference does matter.
Locality of Reference, also known as the Principle of Locality,the phenomenon of the same value or related storage locations being frequently accessed. Locality occurs in time(temporal locality) and in space (spatial locality).
Temporal Locality refers to the reuse of specific data and/or resources within relatively small time durations.
Spatial Locality refers to the use of data elements within relatively close storage locations. Sequential locality, a special case of spatial locality, occurs when data elements are arranged and accessed linearly, eg, traversing the elements in a one-dimensional array.
The number of data pulses required to shift one byte of data from the input to the output of a 4 bit shift register is
Any position independent code is best written using which of the following addressing modes ?
Akilesh Kharvi ? Dec 8 '2016 at 21:52
Answer:Relative.
Explanation:
The relative addressing mode permits the writing of "position-independent code," programs which will be properly executed by the processor regardless of where they are located in memory.
The entire program (together with any necessary data) may be picked up from one region of memory and moved to another with no adverse effect. In order to be location-independent a program may not refer to any specific location by address. All references to memory must be through the use of relative addressing.