what is data structure.in linear and non linear data
structures which one is better?Explain
Answer Posted / rama krishna sidhartha
A data structure is a collection or organization of the data
in computer memory
(or)
A data structure is arrangement of data in a computer's
memory or even disk storage.
In linear and non-linear data structures, linear data
structure is better than non linear data structure. Because
in linear data structure, the elements of the data structure
are represented in the sequence. Whereas, in non linear data
structure is not in sequence.
| Is This Answer Correct ? | 5 Yes | 0 No |
Post New Answer View All Answers
Are the expressions * ptr ++ and ++ * ptr same?
What is the difference between abs() and fabs() functions?
a=10;b= 5;c=3;d=3; if(a printf(%d %d %d %d a,b,c,d) else printf("%d %d %d %d a,b,c,d);
What are the two types of structure?
What is strcmp in c?
Explain the ternary tree?
what are # pragma staments?
What is the explanation for cyclic nature of data types in c?
You have given 2 array. You need to find whether they will
create the same BST or not.
For example:
Array1:10 5 20 15 30
Array2:10 20 15 30 5
Result: True
Array1:10 5 20 15 30
Array2:10 15 20 30 5
Result: False
One Approach is Pretty Clear by creating BST O(nlogn) then
checking two tree for identical O(N) overall O(nlogn) ..we
need there exist O(N) Time & O(1) Space also without extra
space .Algorithm ??
DevoCoder
guest
Posted 3 months ago #
#define true 1
#define false 0
int check(int a1[],int a2[],int n1,int n2)
{
int i;
//n1 size of array a1[] and n2 size of a2[]
if(n1!=n2) return false;
//n1 and n2 must be same
for(i=0;i
What is meant by recursion?
Explain null pointer.
What are types of structure?
Differentiate between a structure and a union.
Tell me what are bitwise shift operators?
What are the data types present in c?