Awesome q2a theme
Ask us anything
Toggle navigation
Email or Username
Password
Remember
Login
Register

I forgot my password
Activity
Questions
Unanswered
Tags
Subjects
Users
Ask
Exams
Recent questions in Programming & DS
Recent
Hot!
Most votes
Most answers
Most views
Featured
Previous GATE
Recent
Hot!
Most votes
Most answers
Most views
Featured
Previous GATE
0
votes
1
answer
Programming Doubt on C
#include<stdio.h> int x=14; int fun(){ return x; } int main(){ int sum=0; for(fun();x;fun()) sum=sum+fun(); printf("%d",sum); return 0; } What will be the output? See , inside for loop , at the time of initialization ... get some sequence point. right? Where will ${\color{Green} {fun()}}$ it get sequence point? Will in this iteration value of sum be 9?
asked
2 days
ago
in
Programming
by
srestha
(
683
points)

16
views
cprogrammingforgate
0
votes
0
answers
techtud.com c & data structure quiz 2020
G is a graph on n vertices and 2n−2 edges. The edges of G can be partitioned into two edgedisjoint spanning trees. Which of the following is NOT true for G? (A)For every subset of k vertices, the induced subgraph has at most ... edgedisjoint paths between every pair of vertices. (D)There are at least 2 vertexdisjoint paths between every pair of vertices.
asked
3 days
ago
in
Programming
by
Sapan Jain 1
(
6
points)

4
views
data_structure
0
votes
0
answers
Hashing, Data structure
In a hash table of size 6, currently the locations 0, 2, 4 and 5 are occupied. The probability of a new record going into location 1, with a hash function resolving collisions by linear probing is (assume uniform hashing). (A) 2/3 (B) 1/3 (C) 1 (D) 1/6 SOURCE https://gateoverflow.in/168123/datastructure Couldn’t understand the solution given.
asked
6 days
ago
in
Programming
by
Harshitkmr
(
10
points)

4
views
0
votes
0
answers
GATE19877a explanation
List the invariant assertions at points $A, B, C,D,$ and $E$ in program given below: Program division (input, output) Const dividend = 81; divisor = 9; Var remainder, quotient:integer begin (*(dividend >= 0) AND (divisor > 0)* ... E*) end https://gateoverflow.in/82425/gate19877a?show=316413#a316413 Can someone elaborate the answer given by Arjun sir in the above link?
asked
Mar 25
in
Programming
by
GATE_aspirant_2021
(
7
points)

5
views
programming
loopinvariants
0
votes
0
answers
ISI 2020 pcb cse
In a binary tree T, for a node v, the LEFTHEIGHT(v) is the length of the longest path from v to any leaf in the left subtree of v. If v has no left child then LEFTHEIGHT(v) = 0. The RIGHTHEIGHT(v) is defined accordingly. A node v ... HEIGHT(v) RIGHTHEIGHT(v) ≤ 1. Design an efficient algorithm that, given a binary tree, enumerates all the nodes which are properly balanced.
asked
Mar 24
in
DS
by
Dn0047
(
10
points)

4
views
binarytree
0
votes
0
answers
What is size of a heap? Is it the number of nodes that satisfy heap property? Please provide some examples, if possible
asked
Mar 23
in
DS
by
akshay7797
(
8
points)

8
views
0
votes
1
answer
CIL MT Exam Binay Tree
The following is the sequence of insertion in a binary tree. 45,65,35,40,33,70,60,75,69 How many numbers of nodes in Left Sub Tree (LST) and Right Sub Tree (RST) of Root node. Ans A. LST – 5, RST3 B. LST – 6, RST2 C. LST – 2, RST6 D. LST – 3, RST5 they have not mentioned BST then how we can get option D
asked
Mar 6
in
Programming
by
VIDYADHAR SHELKE 1
(
7
points)

37
views
algorithms
0
votes
0
answers
coal india 2020: Hashing
In hashing, collision resolution is carried out by close addressing. Which of the following is close addressing technique – I. Buckets (for contiguous storage) II. Chains (for linked storage) A. Only I B. Only II C. I and II D. None i think Buckets for continuous storage is like arrays so it will use linear probing (open addressing) chains – uses closed addressing.
asked
Mar 5
in
Programming
by
rjking7403
(
27
points)

19
views
hashing
+1
vote
1
answer
A Question on CProgramming Pointers (Geeks For Geeks)
asked
Mar 4
in
Programming
by
dishendra
(
7
points)

15
views
programming
datastructures
0
votes
1
answer
Self Doubt C Programming
The site is saying, The output will be : K 75 0.000000 how?
asked
Mar 2
in
Programming
by
shubham02
(
20
points)

20
views
cprogrammingforgate
#cprogramming
#programming
#gatepreparation
#gate
0
votes
1
answer
icegate test series
the number of leaf nodes in a rooted tree of n nodes ,with each nodes having 0 or 3 children node is (A) n/2 (B) (n1)/3 (C) (n1)/2 (D) (2n+1)/3
asked
Mar 1
in
DS
by
DKY123
(
6
points)

23
views
icegatetestseries
0
votes
0
answers
#self Doubts Cprogramming
asked
Feb 21
in
Programming
by
shubham02
(
20
points)

13
views
#gatepreparation
#programming
#cprogramming
#pda
0
votes
2
answers
https://gateoverflow.in/118319/gate2017136
Consider the following code: int bar(int val) { int x=0; while(val>0){ x=x+bar(val1); } return val; } Where does the difference in the functioning of the code occur when the statement x=x+bar(val1); in the above code gets replaced by x=x+bar(val); Please explain the difference between both of them and the way the logic works.
asked
Feb 15
in
Programming
by
HaripriyaKondapally
(
6
points)

20
views
programminginc
cprogrammingforgate
0
votes
0
answers
GATE 2020 CSE paper
If we insert n^2 element to already avl tree of size n then what is its Time Complexity? Theta(n^2) Theta(n^2logn)
asked
Feb 9
in
Programming
by
PRG1499
(
6
points)

48
views
#gate2020
#algorithms#timecomplexity
0
votes
0
answers
Made easy Mock test
can someone please explain the solution? answer is 26.
asked
Feb 5
in
Programming
by
nidhi1604
(
7
points)

42
views
#pointers
#madeeasytestseries
#memocktest1#programming
0
votes
0
answers
Made aesy test series : BFS
Consider the following graph: The minimum size of queue required when performing BFS on above graph is ________. (Take size of queue as by maximum number of elements at any time). What will be the correct answer for the foolowing question?
asked
Feb 5
in
DS
by
vishal burnwal
(
135
points)

31
views
madeeasytestseries
0
votes
0
answers
SELF DOUBT:LINK LiST
Given two singly linked list of size n. The time complexity of computing the union and intersection of two linked list is. a) $O(n)$ and $O(nlogn)$ b) $O(n)$ and $O(n)$ c) $O(nlogn)$ and $O(nlogn)$ d) $O(nlogn)$ and $O(n)$
asked
Feb 2
in
Programming
by
Debapaul
(
699
points)

32
views
0
votes
0
answers
GATE GURU: Pointers
asked
Feb 1
in
Programming
by
Debapaul
(
699
points)

35
views
cprogrammingforgate
0
votes
0
answers
GATE FORUM: HUFFMAN CODING
asked
Jan 31
in
Programming
by
Debapaul
(
699
points)

17
views
algorithms
huffmancode
0
votes
0
answers
GATE GURU: STRUCTURES
asked
Jan 30
in
Programming
by
Debapaul
(
699
points)

24
views
algorithms
0
votes
0
answers
Self Doubt: Recurrence
asked
Jan 29
in
Programming
by
Debapaul
(
699
points)

40
views
algorithms
0
votes
0
answers
Testbook: Mock
In a BST, the key with value 5 was searched after traversing nodes with values 1,3,4,6,7,8,9, not necessarily in that order. What is the probability that the 3rd element on the search path beginning from the root is either 3 or 8?
asked
Jan 29
in
DS
by
Sambhrant Maurya
(
401
points)

83
views
probability
binary_search_tree
0
votes
0
answers
Data Structure can someone tell what is converse and inverse order of pre ,post , inorder travsersal of tree
asked
Jan 29
in
Programming
by
Harsh1198
(
6
points)

10
views
0
votes
0
answers
Applied course test series : Pointers
#include <stdio.h> int main() { char str[]="APPLIED"; const char *ptr; ptr=str; ptr++; printf("%s",ptr); return 0; } In this question my doubt is that since pointer is a constant pointer then why ‘ptr++’ is not giving error?
asked
Jan 28
in
Programming
by
vishal burnwal
(
135
points)

34
views
programminginc
programming
0
votes
0
answers
ACE Test FLTprogram
What is difference between this program and GATE2019 question(link given below)? In this test question, it is taking value by address, so that is the reason to not returning value to the main? But here https://gateoverflow.in/302830/gate201918 just local variable returning the value, Sothe value is intact in main() program too?
asked
Jan 28
in
Programming
by
srestha
(
683
points)

26
views
programming
0
votes
0
answers
applied gate mock 5
[closed]
asked
Jan 27
in
DS
by
abhinav649
(
67
points)

37
views
hashing
0
votes
1
answer
ACE Full length Mock test 11
Please explain the solution along with the concept.
asked
Jan 25
in
Programming
by
Rudr Pawan
(
734
points)

32
views
aceacademytestseries
0
votes
0
answers
Binary Search Tree
Consider the following set of keys : [K,L,C,R,B,E,L,A,D]. In how many different order these keys can be inserted into BST such that the resultant tree looks like the below given tree:
asked
Jan 25
in
Programming
by
zoboknows
(
6
points)

32
views
binary_search_tree
0
votes
1
answer
madeeasy test series answer doubt
https://csedoubts.gateoverflow.in/8774/madeeasytestseries2020minheap what is the correct answer? 6 or 7
asked
Jan 25
in
DS
by
eyeamgj
(
40
points)

31
views
0
votes
0
answers
FULL SYLLABUS TEST6 (ADVANCE LEVEL) GATE 2020 question 61
asked
Jan 25
in
Programming
by
Pratyush Priyam Kuan
(
804
points)

25
views
madeeasytestseries
data_structure
trees
0
votes
0
answers
ISRO2020 Exam
The Postorder traversal of a binary tree is ACEDBHIGF. the preorder Traversal is? ABCDEFGHI FBADCEGIH FABCDEGHI ABDCEFGIH
asked
Jan 25
in
DS
by
aditya dhanraj
(
7
points)

13
views
#isro2020
0
votes
0
answers
Finding subarray with k sum
#include<bits/stdc++.h> using namespace std; bool subArrayExist(int a[],int n); int main() { int n; // Size of array cin>>n; int a[n]; for(int i=0;i<n;i++) cin>>a[i]; int k; cin>>k; bool check=subArrayExist(a,n); ... map[sum]==true) return true; map[sum]=true; } return false; } Where I am going wrong ? Please tell me , It will be very helpful.
asked
Jan 25
in
Programming
by
ujjwalgupta
(
6
points)

8
views
0
votes
0
answers
Made easy test series : C programming
Consider the following program: Which of the following statement is true? I. It results 9 II. Runtime error III. Compilation error Assume all the header files and function definition correctly done. How to identify which error will be generated?
asked
Jan 23
in
Programming
by
vishal burnwal
(
135
points)

31
views
madeeasytestseries
+1
vote
1
answer
GATE GURU: SPANNING TREE
How to solve this question quickly? Is there any algorithm? I am able to solve it by trying out all the combinations and it has taken me nearly $5+$ $mins$ Any way to solve this quickly. A complete graph can have $n^{n2}$ spanning trees, and since this graph is nearly complete except one edge can we derive some $shortcut$ from this fact?
asked
Jan 22
in
Programming
by
Debapaul
(
699
points)

35
views
algorithms
0
votes
0
answers
Madeeasy test series  Retrieve address of element in matrix
asked
Jan 21
in
DS
by
luc_Bloodstone
(
36
points)

20
views
madeeasytestseries
data_structure
algorithms
0
votes
0
answers
Madeeasy test series  recurrence relation
asked
Jan 21
in
DS
by
luc_Bloodstone
(
36
points)

7
views
recurrencerelations
madeeasytestseries
timecomplexity
algorithms
0
votes
0
answers
Made Easy test series data structure binary search tree
asked
Jan 21
in
DS
by
Ram Swaroop
(
270
points)

26
views
madeeasytestseries
data_structure
bst
binary_search_tree
0
votes
0
answers
MADE EASY MOCK
Isnt number of bits passed is $4$, say when $i=5$ we will pass $0101$ right? and in case of $2$ we will pass $0010$ right?
asked
Jan 21
in
Programming
by
Debapaul
(
699
points)

20
views
algorithms
0
votes
0
answers
Enqueue and Dequeue
asked
Jan 20
in
DS
by
Akash Papnai
(
17
points)

6
views
data_structure
queue
+1
vote
0
answers
Gatebook Heaps
What is the minimum number of comparisons required in the worst case to find the smallest element in a minheap? Can someone please explain the procedure. The answer is 50*51 / 2
asked
Jan 20
in
DS
by
neeraj_bhatt
(
275
points)

9
views
heap
gatebook
Page:
1
2
3
4
...
10
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
Welcome to GATE CSE Doubts, where you can ask questions and receive answers from other members of the community.
Top Users
Apr 2020
!KARAN
36 Points
lazygatestudent
5 Points
AngeloAlba89
5 Points
WillKnisley
5 Points
TamieMcvay4
5 Points
Satyaki Das
5 Points
akansha03
5 Points
srestha
3 Points
Shivateja MST
2 Points
souren
2 Points
Monthly Top User and those within 60% of his/her points will get a share of monthly revenue of GO subject to a minimum payout of Rs. 500. Current monthly budget for Top Users is Rs. 75.
All categories
General Aptitude
72
Engineering Mathematics
434
Digital Logic
213
Programming & DS
362
Programming
280
DS
81
Algorithms
314
Theory of Computation
458
Compiler Design
223
Operating System
328
Databases
335
CO & Architecture
288
Computer Networks
280
Non GATE
7
Others
82
Admissions
68
Exam Queries
39
Tier 1 Placement Questions
2
Job Queries
5
Projects
1
Recent questions in Programming & DS
3,511
questions
1,656
answers
10,449
comments
90,037
users