The Gateway to Computer Science Excellence
For all GATE CSE Questions
Toggle navigation
GATE Overflow
Facebook Login
Google Login
or
Email or Username
Password
Remember
Login
Register

I forgot my password
All Activity
Questions
Unanswered
Tags
Subjects
Users
Ask
Previous
Blogs
New Blog
Exams
First time here? Checkout the
FAQ
!
x
×
Close
Use the google search bar on side panel. It searches through all previous GATE/other questions. For hardcopy of previous year questions please see
here
Recent questions tagged datastructure
Webpage for Data Structures
0
votes
0
answers
1
Circular Link List Insertion and Deletion
asked
4 hours
ago
in
Programming
by
srestha
Veteran
(
101k
points)

17
views
linkedlists
datastructure
0
votes
0
answers
2
Karumanchi
There is a singly linked list. We have a pointer to a particular node(it is not tail node). what is the time and space complexity required to delete this node? my approach is... As there is no previous pointer so we traverse the list from the starting to just ... complexity as O(n) and space complexity O(1). but in the book the time complexity is mentioned O(1) where am I going wrong?
asked
4 hours
ago
in
DS
by
aditi19
Active
(
1.4k
points)

14
views
timecomplexity
linkedlists
datastructure
0
votes
0
answers
3
Tree Traversal
asked
18 hours
ago
in
Programming
by
Na462
Loyal
(
7k
points)

48
views
datastructure
binarytree
0
votes
1
answer
4
Reversing Singly Linked List
To reverse a Singly Linked List is the below is correct code? (or) need to change Struct node *reverse(struct node *start) { Struct node *prev,*ptr,*next; prev=NULL; ptr=start; while(ptr!=NULL) { next=ptr>link; ptr>link=prev; prev=ptr; ptr=next; } start=prev; return start; Plz tell me, is here all link updating correctly?
asked
1 day
ago
in
Programming
by
srestha
Veteran
(
101k
points)

33
views
linkedlists
datastructure
0
votes
0
answers
5
Linked list Quiz
Consider an unrolled linked list with $n$ elements.This list stores multiple elements in each node. What is the worst case time complexity to find the $k^{th}$ element if the number of nodes and the number of elements in each node are equal? $A)O(n)$ $B)O(\sqrt n)$ $C)O(nlogn)$ $D)O(n^{2})$
asked
1 day
ago
in
Programming
by
Lakshman Patel RJIT
Boss
(
14.7k
points)

40
views
datastructure
linkedlists
0
votes
0
answers
6
GATEBOOKDSA4_8
Consider a sorted array A of n integer elements, A[0]...A[n − 1]. A search operation is to be performed on this array using .Binary search algorithm. If the element being searched is in fact the last element of the array, what is the difference between the index of element ... , \frac{7n1}{8}=\frac{n7}{8}$ This is my answer.But it matches none of the options. Where I went wrong?
asked
5 days
ago
in
Programming
by
Ayush Upadhyaya
Boss
(
16.2k
points)

26
views
datastructure
binarysearch
algorithms
0
votes
0
answers
7
Max heap when stored in an array is always in sorted order
asked
5 days
ago
in
DS
by
sripo
Junior
(
755
points)

50
views
sorting
binaryheap
arrays
heap
datastructure
algorithms
0
votes
0
answers
8
DATA STRUCTURES
Can anyone explain answer is A
asked
Nov 9
in
DS
by
nag.swarna
(
217
points)

152
views
datastructure
strings
0
votes
1
answer
9
How to understand difference between n/2 and log(n) when comes to operations on a binary tree
asked
Nov 8
in
DS
by
sripo
Junior
(
755
points)

51
views
datastructure
binarytree
heap
binaryheap
0
votes
0
answers
10
Depth First Search
asked
Nov 7
in
Programming
by
Na462
Loyal
(
7k
points)

72
views
dfs
datastructure
graphalgorithms
0
votes
1
answer
11
Binary Search Tree
Consider the following routine bool do(struct node *root) { if(!root) return true; else if(( root > left != NULL && root > data < root > left> data) (root>right != NULL && root > data > root  ... > right)); } What does they do() check whether a given tree is: $A)$ Max heap $B)$ Min Heap $C)$BST $D)$ Binary Tree
asked
Nov 6
in
DS
by
Lakshman Patel RJIT
Boss
(
14.7k
points)

47
views
datastructure
binarysearchtree
0
votes
1
answer
12
AVL Tree
The minimum number of node in an AVL Tree of height $10$ is ____________
asked
Nov 6
in
DS
by
Lakshman Patel RJIT
Boss
(
14.7k
points)

41
views
datastructure
avltree
0
votes
0
answers
13
Rank of the index
Consider the following What is the rank(index) of the node $50?$
asked
Nov 6
in
DS
by
Lakshman Patel RJIT
Boss
(
14.7k
points)

58
views
datastructure
testseries
0
votes
0
answers
14
Made Easy Booklet
Suppose a binary tree has only three nodes A, B and C and you are given that the postorder traversal for the tree is BAC. The exact preorder traversal for the tree is. CAB ABC CBA A definite preorder traversal cannot be determined from the information given
asked
Nov 6
in
DS
by
shgarg
(
31
points)

41
views
datastructure
binarytree
madeeasybooklet
treetraversal
0
votes
0
answers
15
Intersection among elements of Linked List
asked
Nov 4
in
DS
by
srestha
Veteran
(
101k
points)

153
views
linkedlists
datastructure
0
votes
0
answers
16
AVL TREES
Please suggest how to learn AVL rotation in AVL trees and some good practice questions or link would be so much helpful Thanks
asked
Nov 2
in
Programming
by
Mayankprakash
Junior
(
801
points)

47
views
avltree
tree
datastructure
0
votes
1
answer
17
trees
formula for which maximum number of nodes will be present in complete narray tree?
asked
Nov 2
in
DS
by
suneetha
(
331
points)

24
views
datastructure
0
votes
1
answer
18
2DArray
Consider a 2 dimensional array A[40 ..... 95, 40 ..... 95] in lower triangular matrix representation. The size of each element in the array is 1 byte. If the array is implemented in the memory in the form of row major order and base address of the array is 1000, the address of A[66] [50] will be ________.
asked
Nov 1
in
DS
by
Ankish Gupta 3
(
109
points)

52
views
programminginc
arrays
pointers
datastructure
0
votes
1
answer
19
Permutations, TIFR2011B30
What does it mean when they say "An array A[1...n] consists of a permutation of numbers 1....n.".? Also I'd be grateful if you give some example.
asked
Nov 1
in
Numerical Ability
by
Mizuki
Active
(
1k
points)

30
views
datastructure
permutationsandcombinations
arrays
usertifr2011
usermod
generalaptitude
+1
vote
0
answers
20
test series
Consider an empty binary search tree of height $1.$We need to fill the following sequence of numbers in it $: 11, 12, 13, 14, 15, 16, 17.$The number of ways in which the numbers can be inserted in an empty binary search tree, such that the resulting tree has height $6,$ is _____________ $A)2$ $B)4$ $C)32$ $D)64$
asked
Oct 28
in
Programming
by
mitesh kumar
(
253
points)

156
views
datastructure
binarysearchtree
testseries
0
votes
0
answers
21
Selfdoubt
Is this recurrence relation valid: N(h)=N(h1)+1+(N(h1)2) where N(h) denotes minimum no. of nodes in a binary tree of height h. N(h1) is used for left subtree and N(h1)2 is used for right subtree. This is in reference to this question: https://gateoverflow.in/3811/gate2005it50
asked
Oct 28
in
Programming
by
satendra
(
255
points)

23
views
datastructure
0
votes
0
answers
22
Red Black Tree
What is the largest possible number of internal nodes in a redblack tree with black height $4?$
asked
Oct 28
in
DS
by
Lakshman Patel RJIT
Boss
(
14.7k
points)

24
views
datastructure
binarytree
0
votes
0
answers
23
Binary Search Tree
Consider a binary search tree for the following sequence of nodes $a,b,g,f,c,e,d$ What is the resultant tree if splaying is done at $'d'.$
asked
Oct 28
in
DS
by
Lakshman Patel RJIT
Boss
(
14.7k
points)

43
views
datastructure
binarysearchtree
0
votes
0
answers
24
Binary tree
Assume that there is at most $1$ node at height $0$ then a binary tree with $7$ node: $1)$ Has Exactly $8$ edges $2)$ The height of this binary tree is at least $2$ and at most $6$ $3)$ The depth of the root node is zero Which of the above statement are true? $A)1$ $B)3$ $C)2 $ and $3$ $D)1 $ and $ 2$
asked
Oct 27
in
DS
by
Lakshman Patel RJIT
Boss
(
14.7k
points)

38
views
datastructure
binarytree
0
votes
0
answers
25
Linked list implementation of Previous
Consider the following function: Find(Element Type X,List L) { Position Prev_Pos,XPos; Prev_Pos=Find Previous(X,L); if(Prev_Pos>Next!=NULL) /* found */ { XPos=Prev_Pos>Next; Prev_Pos>Next=XPos ... adjusting lists $B)$Linked list implementation of singly linked lists $C)$Linked list implementation of doubly linked lists $D)$None of these
asked
Oct 26
in
DS
by
Lakshman Patel RJIT
Boss
(
14.7k
points)

29
views
datastructure
linkedlists
0
votes
0
answers
26
Reverse Linked list
What is the time complexity of the bestknown algorithm to reverse a doubly linked list? $A) O(n)$ $B) O(logn)$ $C) O(1)$ $D) O(n^{2})$
asked
Oct 26
in
DS
by
Lakshman Patel RJIT
Boss
(
14.7k
points)

36
views
datastructure
linkedlists
0
votes
0
answers
27
Advance test algorithms
i am getting 36 please confirm given answer is 15
asked
Oct 23
in
Programming
by
Prince Sindhiya
Active
(
4.5k
points)

31
views
datastructure
and
programming
0
votes
0
answers
28
Binary Tree
I know the answer. But is there any general FORMULA for it? If yes, please provide the complete derivation of it. In the solution, they used $\rightarrow 2^{h1}+1.$ I tried but I am not able to derive it.
asked
Oct 22
in
Programming
by
Soumya29
Boss
(
13.7k
points)

47
views
datastructure
binarytree
0
votes
2
answers
29
Recursion
What is Head recursion and Tail Recursion??
asked
Oct 22
in
Programming
by
Lakshman Patel RJIT
Boss
(
14.7k
points)

37
views
datastructure
recursion
0
votes
1
answer
30
stack underflow
A stack of size (1 to N) and the initial position of top pointer is 0. get(i,S) is aroutine to get ith element from stack 'S' with respect to top. then,what is the underflow condition on stack to perform get() operation? $A) topi<N$ $B) topi+1<=N$ $C) topi<=0$ $D) topi+1<=0$
asked
Oct 22
in
DS
by
Lakshman Patel RJIT
Boss
(
14.7k
points)

55
views
datastructure
stack
Page:
1
2
3
4
5
6
...
34
next »
Quick search syntax
tags
tag:apple
author
user:martin
title
title:apple
content
content:apple
exclude
tag:apple
force match
+apple
views
views:100
score
score:10
answers
answers:2
is accepted
isaccepted:true
is closed
isclosed:true
Recent Posts
SCREENSHOT
Basic LaTeX guide
IIT Madras Phd
Databases GO Classroom
Happy Birthday Sir Arjun
Follow @csegate
Gatecse
Recent questions tagged datastructure
Recent Blog Comments
Add JOB DEADLINE SEQUENCING to Greedy.
Hmm as an active user on this platform, I can...
Copypasting would not help in writing the...
Sir for final year student who have exam in...
42,686
questions
48,650
answers
156,451
comments
63,961
users