Facebook Login
Login
Register
Q&A
Questions
Unanswered
Tags
Subjects
Users
Ask
Prev
Blogs
New Blog
Exams
Recent Posts
Some Good courses on System Development
My GATE preparation experience (GATE CS 2020 AIR-13)
GATE CSE: IIST Admissions
GATE CSE: IIITH Admissions
Video Solution for Previous Year GATE Questions
Subjects
All categories
General Aptitude
(2.4k)
Engineering Mathematics
(8.4k)
Digital Logic
(2.9k)
Programming and DS
(5k)
Algorithms
(4.4k)
Theory of Computation
(6.2k)
Compiler Design
(2.2k)
Operating System
(4.6k)
Databases
(4.2k)
CO and Architecture
(3.4k)
Computer Networks
(4.2k)
Non GATE
(1.6k)
Others
(2k)
Admissions
(595)
Exam Queries
(573)
Tier 1 Placement Questions
(23)
Job Queries
(72)
Projects
(18)
Follow @csegate
Recent questions and answers in Algorithms
Recent Blog Comments
50% as in 120 or the 50% of total number of...
congrats!. Best of luck for your next endeavour.
What is the average package offered to mtech cse...
congrats very much
Congratulations ! Indeed Previous year questions...
Recent questions and answers in Algorithms
0
votes
1
answer
1
2
views
CAT 2013e: 1
The sum of the possible values of $x$ in the equation $ mid x + 9 mid + mid x - 11 mid = 24$ is? (Numerical answer type)
answered
Jun 9
in
Algorithms
by
gatecse
Boss
(
23.1k
points)
2
views
33
numerical-answers
0
votes
1
answer
2
2
views
CAT 2013e: 2
The lines $p(p^{2} - 1)x - y + q = 0$ and $(p^{2} - 1)^{2} x + (p^{2} - 1)y + 2q = 0$ are Perpendicular to a common line for? More than two values of $p$ Exactly one value of $p$ No value of $p$ Exactly two values of $p$
answered
Jun 9
in
Algorithms
by
gatecse
Boss
(
23.1k
points)
2
views
33
0
votes
1
answer
3
2
views
CAT 2013ss: 1
The sum of the possible values of $x$ in the equation $\mid x + 9 \mid + \mid x - 11\mid = 24$ is?\\ (Numerical answer type)
answered
Jun 9
in
Algorithms
by
gatecse
Boss
(
23.1k
points)
2
views
ee
numerical-answers
0
votes
1
answer
4
2
views
CAT 2013ss: 2
The lines $p(p^{2} - 1)x - y + q = 0$ and $(p^{2} - 1)^{2} x + (p^{2} - 1)y + 2q = 0$ are Perpendicular to a common line for? More than two values of $p$ Exactly one value of $p$ No value of $p$ Exactly two values of $p$
answered
Jun 9
in
Algorithms
by
gatecse
Boss
(
23.1k
points)
2
views
ee
0
votes
1
answer
5
2
views
CAT 2013x: 1
The sum of the possible values of $x$ in the equation $\mid x + 9 \mid + \mid x - 11\mid = 24$ is?\\<br /> (Numerical answer type)
answered
Jun 9
in
Algorithms
by
gatecse
Boss
(
23.1k
points)
2
views
uuu
numerical-answers
0
votes
1
answer
6
2
views
CAT 2013x: 2
The lines $p(p^{2} - 1)x - y + q = 0$ and <br /> $(p^{2} - 1)^{2} x + (p^{2} - 1)y + 2q = 0$ are Perpendicular to a common line for?<br /> <br /> <ol style="list-style-type:upper-alpha"><li> More than two ... ; No value of $p$<br /> </li><li>Exactly two values of $p$<br /> <br /> <br /> </li></ol>
answered
Jun 9
in
Algorithms
by
gatecse
Boss
(
23.1k
points)
2
views
uuu
0
votes
1
answer
7
2
views
CAT 2013m: 1
The sum of the possible values of $x$ in the equation $\mid x + 9 \mid + \mid x - 11\mid = 24$ is?\\<br /> (Numerical answer type)
answered
Jun 9
in
Algorithms
by
gatecse
Boss
(
23.1k
points)
2
views
bb
numerical-answers
0
votes
1
answer
8
2
views
CAT 2013m: 2
The lines $p(p^{2} - 1)x - y + q = 0$ and <br /> $(p^{2} - 1)^{2} x + (p^{2} - 1)y + 2q = 0$ are Perpendicular to a common line for?<br /> <br /> <ol style="list-style-type:upper-alpha"><li> More than two ... ; No value of $p$<br /> </li><li>Exactly two values of $p$<br /> <br /> <br /> </li></ol>
answered
Jun 9
in
Algorithms
by
gatecse
Boss
(
23.1k
points)
2
views
bb
0
votes
1
answer
9
1
view
CAT 2010ccc: 1
The sum of the possible values of $x$ in the equation $\mid x + 9 \mid + \mid x - 11\mid = 24$ is?\\ (Numerical answer type)
answered
Jun 9
in
Algorithms
by
gatecse
Boss
(
23.1k
points)
1
view
nnn
numerical-answers
0
votes
1
answer
10
2
views
CAT 2010ccc: 2
The lines $p(p^{2} - 1)x - y + q = 0$ and $(p^{2} - 1)^{2} x + (p^{2} - 1)y + 2q = 0$ are Perpendicular to a common line for? More than two values of $p$ Exactly one value of $p$ No value of $p$ Exactly two values of $p$
answered
Jun 9
in
Algorithms
by
gatecse
Boss
(
23.1k
points)
2
views
nnn
0
votes
2
answers
11
154
views
Using Horner method and Brutef force method what will be the Time Complexity of
Using Horner method and Brute force what will be the Time Complexity of 4x4+7x3-2x2+3x+6
answered
May 5
in
Algorithms
by
crystal shadow
(
29
points)
154
views
time-complexity
algorithms
0
votes
1
answer
12
188
views
recurrence relation
T(n)=5 T ($\frac{n}{2}$+16) + n2 please tell the solution as i m getting confused
answered
May 4
in
Algorithms
by
ramcharantej_24
(
59
points)
188
views
relations
recurrence
algorithms
time-complexity
recurrence-eqation
0
votes
3
answers
13
210
views
Made Easy Test Series:Algorithm-Recurrence Relation
What is the solution of recurrence relation $T\left ( n \right )=T\left ( n-1 \right )+n$
answered
May 4
in
Algorithms
by
AbhayPrajapati
(
75
points)
210
views
algorithms
time-complexity
recurrence-eqation
0
votes
1
answer
14
36
views
Cormen Edition 3 Exercise 2.1 Question 4 (Page No. 22-23)
Consider the problem of adding two $n$-bit binary integers, stored in two $n$-element arrays $A$ and $B$.The sum of the two integers should be stored in binary form in an $(n+1)$-element array $C$. State the problem formally and write pseudocode for adding the two integers.
answered
May 3
in
Algorithms
by
noob_coder
Junior
(
855
points)
36
views
cormen
algorithms
introduction
descriptive
+3
votes
4
answers
15
207
views
TIFR2020-B-10
Among the following asymptotic expressions, which of these functions grows the slowest (as a function of $n$) asymptotically? $2^{\log n}$ $n^{10}$ $(\sqrt{\log n})^{\log ^{2} n}$ $(\log n)^{\sqrt{\log n}}$ $2^{2^{\sqrt{\log\log n}}}$
answered
May 3
in
Algorithms
by
DIBAKAR MAJEE
Active
(
1.2k
points)
207
views
tifr2020
algorithms
asymptotic-notations
time-complexity
+1
vote
2
answers
16
245
views
Asymptotic Notation theta property
If $T1(n) = \Theta(f(n))$ & $T2(n) = \Theta(f(n))$ Then, Is $T1(n) + T2(n) = O(f(n))$ If yes, then how?
answered
Apr 29
in
Algorithms
by
lokeshsolanki17
(
123
points)
245
views
asymptotic-notations
algorithms
time-complexity
growth-rate
0
votes
2
answers
17
683
views
What will be the complexity of given modified merge sort
Shiva modified merge sort as: divide the array into 3 equal parts insttead of 2. sort each part do a 3 way merge. What can we conclude about modified three way merge sort? A. It has same worst case complexity as normal merge sort B. ... 3 level. C. It is more complex due to 3 way merge D. The algorithm will not work perfectly for some inputs.
answered
Apr 29
in
Algorithms
by
Mohit Kumar 6
Active
(
2.1k
points)
683
views
algorithms
sorting
+2
votes
5
answers
18
126
views
NIELIT 2016 MAR Scientist B - Section C: 12
Which of the following sorting algorithms does not have a worst case running time of $O(n^2)$ ? Insertion sort. Merge sort. Quick sort. Bubble sort.
answered
Apr 29
in
Algorithms
by
ptarafdar010
(
11
points)
126
views
nielit2016mar-scientistb
0
votes
1
answer
19
40
views
Cormen Edition 3 Exercise 8.2 Question 2 (Page No. 196)
Prove that COUNTING-SORT is stable.
answered
Apr 28
in
Algorithms
by
abhishek tiwary
Active
(
3.8k
points)
40
views
cormen
algorithms
sorting
countingsort
descriptive
+2
votes
1
answer
20
181
views
Can anyone make the table of Complexities, No. of swaps required for N elements for all type of sorts?
answered
Apr 28
in
Algorithms
by
Mohit Kumar 6
Active
(
2.1k
points)
181
views
algorithms
time-complexity
sorting
0
votes
1
answer
21
43
views
Cormen Edition 3 Exercise 10.2 Question 6 (Page No. 241)
The dynamic-set operation $UNION$ takes two disjoint sets $S_1$ and $S_2$ as input, and it returns a set $S=S_1 \cup S_2$ consisting of all the elements of $S_1$ and $S_2$.The sets $S_1$ and $S_2$ are usually destroyed by the operation. Show how to support $UNION$ in $O(1)$ time using a suitable list data structure.
answered
Apr 28
in
Algorithms
by
abhishek tiwary
Active
(
3.8k
points)
43
views
cormen
data-structures
linked-lists
descriptive
0
votes
1
answer
22
32
views
NIELIT 2016 DEC Scientist B (IT) - Section B: 7
What is the type of the algorithm used in solving the $4$ Queens problem? Greedy Branch and bound Dynamic Programming Backtracking
answered
Apr 28
in
Algorithms
by
abhishek tiwary
Active
(
3.8k
points)
32
views
nielit2016dec-scientistb-it
0
votes
2
answers
23
28
views
NIELIT 2016 DEC Scientist B (IT) - Section B: 8
Selection sort,quick sort is a stable sorting method True,True False,False True,False False,True
answered
Apr 28
in
Algorithms
by
abhishek tiwary
Active
(
3.8k
points)
28
views
nielit2016dec-scientistb-it
+2
votes
2
answers
24
3.2k
views
Is Bellman Ford Dynamic Programming approach ?
Is bellman ford a dynamic programming approach? If yes, what is the reason behind it? How do we find an optimal substructure and overlapping sub problems in this ?
answered
Apr 28
in
Algorithms
by
kunal goswami
Junior
(
749
points)
3.2k
views
algorithms
shortest-path
graph-algorithms
0
votes
1
answer
25
136
views
Complexity
We have for Counting Sort, O(n+k), for a simple uniform hashing, search operation of O(1+alpha) etc. What is the meaning when we say n + k? Is it that counting sort will depend on either n or k? Because there are separate loops in counting sort running on O(n) and O(k) separately. What does O(n + k) mean? What kind of algorithms have this summation for their order, generally?
answered
Apr 28
in
Algorithms
by
Mohit Kumar 6
Active
(
2.1k
points)
136
views
algorithms
time-complexity
asymptotic-notations
sorting
0
votes
1
answer
26
53
views
Cormen Edition 3 Exercise 8.4 Question 2 (Page No. 204)
Explain why the worst-case running time for bucket sort is $\Theta(n^2)$. What simple change to the algorithm preserves its linear average-case running time and makes its worst-case running time $O(n\ lg\ n)$?
answered
Apr 28
in
Algorithms
by
Mohit Kumar 6
Active
(
2.1k
points)
53
views
cormen
algorithms
sorting
bucketsort
descriptive
+1
vote
2
answers
27
165
views
Bucket sort
1. Is bucket sort always stable or does it depend on the sorting subroutine used by bucket sort toe sort the buckets? 2. Bucket sort is always NOT inplace.Is this correct?
answered
Apr 27
in
Algorithms
by
Mohit Kumar 6
Active
(
2.1k
points)
165
views
sorting
algorithms
+1
vote
1
answer
28
258
views
Find the element that appears once in a sorted array.
In a sorted array, every element is repeated more than once except one. what will be the time complexity to find that element in the worst case?
answered
Apr 27
in
Algorithms
by
Mohit Kumar 6
Active
(
2.1k
points)
258
views
algorithms
sorting
+3
votes
1
answer
29
297
views
MadeEasy Test Series 2017: Algorithms - Sorting
Given a set of n distinct integers, it is required to determine the three smallest integers of this array using comparisons, The no of comparison needed are (A) n + O( log n ) (B) n + O( 1 ) (C) O ( n ) (D) O ( log2n ) ANSWER GIVEN ::- A
answered
Apr 27
in
Algorithms
by
Mohit Kumar 6
Active
(
2.1k
points)
297
views
made-easy-test-series
algorithms
sorting
madeeasy-testseries-2017
+2
votes
1
answer
30
127
views
Ace Test series: Algorithms - Sorting
answered
Apr 27
in
Algorithms
by
Mohit Kumar 6
Active
(
2.1k
points)
127
views
ace-test-series
algorithms
sorting
0
votes
2
answers
31
39
views
UGCNET-Dec2006-II: 22
Binary search tree is an example of : Divide and conquer technique. Greedy algorithm. Back tracking. Dynamic Programming.
answered
Apr 27
in
Algorithms
by
DIBAKAR MAJEE
Active
(
1.2k
points)
39
views
ugcnetdec2006ii
+2
votes
2
answers
32
1.3k
views
#Algorithms Time Complexity Analysis of Multistage Graph using Bottom Up Dynamic Programming
answered
Apr 26
in
Algorithms
by
happysingh
(
49
points)
1.3k
views
algorithms
dynamic-programming
+1
vote
1
answer
33
107
views
GeeksForGeeks analysis-of-algorithms Question 15
In a modified merge sort, the input array is splitted at a position one-third of the length(N) of the array. What is the worst case time complexity of this merge sort?
answered
Apr 24
in
Algorithms
by
Himanshu Kumar Gupta
Junior
(
715
points)
107
views
asymptotic-notations
0
votes
1
answer
34
94
views
made easy adv 2018
The median of n elements can be found in O(logn) time.which one of the following is correct about worst case time complexity of quick sort,if always median is selected as pivot element? a)O(logn) b)O(n) c)O(nlogn) d)O(nloglogn)
answered
Apr 20
in
Algorithms
by
DIBAKAR MAJEE
Active
(
1.2k
points)
94
views
+1
vote
2
answers
35
276
views
Binary Search
There are two sorted list each of length n. An element to be searched in the both the lists. The lists are mutually exclusive. The maximum number of comparisons required using binary search and find its time complexity?
answered
Apr 20
in
Algorithms
by
DIBAKAR MAJEE
Active
(
1.2k
points)
276
views
data-structures
binary-search
+3
votes
4
answers
36
626
views
Ace Test Series: Algorithms - Sorting
Consider bottom-up merge sort working on 'n' elements. Assume 'n' is a power of 2. The minimum number of comparisons in order to get sorted list is (A) (n log n) / 2 (B) n lon n - n + 1 (C) n log n (D) n log n + n
answered
Apr 20
in
Algorithms
by
Sushovan95
(
15
points)
626
views
merge-sort
ace-test-series
sorting
algorithms
+1
vote
2
answers
37
273
views
NTA NET DEC 2019 (Post-correspondence)
$\mathbf{Q57}$ Let $\mathrm{A={001,0011,11,101}}$ and $\mathrm{B={01,111,111,010}}$. Similarly , Let $\mathrm{C={00,001,1000}}$ and $\mathrm{B={0,11,011}}$. Which of the following pairs have a post correspondence solution? $\mathrm{1)\; Only \;pair \;(A,B) }$ ... $\mathrm{\; 4) \;Neither \;(A,B) \;nor\; (C,D) }$
answered
Apr 20
in
Algorithms
by
sapna_Nsingh
(
15
points)
273
views
post
post-correspondence-problem
0
votes
1
answer
38
88
views
Question_bank
f(n)=O(g(n)) Which of the following is True? 2^f(n)=O(2^(g(n)) log(f(n))=O(log(g(n)) f(n)=O(f(n/2)) f(n)=O(f(n)^2)
answered
Apr 18
in
Algorithms
by
Himanshu Kumar Gupta
Junior
(
715
points)
88
views
algorithms
time-complexity
asymptotic-notations
+2
votes
1
answer
39
157
views
MadeEasy Test Series: Algorithms - Sorting
An array of size n is known to be sorted except for the 1st k elements and the last k elements, where k is a constant. which of the following algorithm is the best choice for sorting the array A? Quick Sort or Insertion Sort? given answer is the insertion ... k), and it will take O(klogk) in average case and O(k^2) in the worst case. what's wrong in that?
answered
Apr 14
in
Algorithms
by
GATE2021
(
95
points)
157
views
made-easy-test-series
algorithms
sorting
+35
votes
4
answers
40
6.2k
views
Gate2000-2.19
Let $G$ be an undirected graph. Consider a depth-first traversal of $G$, and let $T$ be the resulting depth-first search tree. Let $u$ be a vertex in $G$ and let $v$ be the first new (unvisited) vertex visited after visiting $u$ in the traversal. Which of the following statement is ... leaf in $T$ If $\{u, v\}$ is not an edge in $G$ then $u$ and $v$ must have the same parent in $T$
answered
Apr 13
in
Algorithms
by
immanujs
Active
(
1.4k
points)
6.2k
views
gate2000
algorithms
graph-algorithms
normal
To see more, click for all the
questions in this category
.
...