Skip to main content

Algorithms

Algorithms

Pick an Algorithms subtopic from the cards below — asymptotics through complexity classes — each tagged with marks weightage, importance, GATE samples, and flashcards.

7–10 marks · prioritise Must-score 7 detailed lessons Free guide

Learning outcomes

  • Compare Θ, O, and Ω on standard examples
  • Apply BFS, DFS, Dijkstra, and Kruskal/Prim ideas
  • Set up a simple DP recurrence
  • Spot the right algorithm from a problem stem

Overview

Algorithms in GATE CSE usually carries about 7–10 marks across asymptotics, sorting/searching, divide & conquer, greedy, DP, graph algorithms, and P/NP basics.

You do not need to write long code — recognise the algorithm, compute a result or complexity, and apply GATE-level correctness ideas.

Use the weightage table to prioritise Must-score topics (sorting, DP, graphs) first, then open each lesson for concepts, samples, practice, and flashcards.

Marks & importance

Topic-wise weightage (indicative)

Algorithms as a whole usually contributes about 7–10 marks in GATE CSE. Ranges below split that band across subtopics for revision planning — exact marks vary by year.

Topic Typical marks Importance Why it matters
Asymptotic Analysis ~1–1.5 High Big-O / Θ / Ω comparisons, growth-rate ordering, and loop-complexity questions appear almost every year.
Sorting & Searching ~1.5–2 Must-score Merge, quick, heap and counting/radix sort properties, stability, and comparison counts are repeat favourites.
Divide & Conquer ~0.5–1 High Master-theorem style recurrence solving and D&C algorithm costs (merge sort, binary search, Strassen).
Greedy Algorithms ~1–1.5 High Activity selection, Huffman coding, fractional knapsack, MST intuition, and the exchange-argument idea.
Dynamic Programming ~1.5–2 Must-score LCS, knapsack, matrix-chain, and coin-change style recurrences with table-filling and complexity questions.
Graph Algorithms ~2–3 Must-score BFS/DFS, topological sort, Dijkstra, Bellman-Ford, Floyd-Warshall, Kruskal and Prim give the steadiest high-yield marks.
Complexity Classes ~0.5–1 Moderate P, NP, NP-hard and NP-complete at MCQ depth: definitions, reductions direction, and classic NPC problems.
  • Must-score Lock these first — short, high-accuracy items.
  • High Core building blocks; appear often in MCQ/NAT form.
  • Moderate Less frequent, but clean marks when prepared.
Topic map

Algorithms — detailed lessons

Open each subtopic from the left menu (or the cards below). Together they cover about ~28 hours of first-pass Algorithms aligned to the GATE CSE syllabus: asymptotics, sorting & searching, divide & conquer, greedy, DP, graph algorithms, and complexity classes — with GATE-style samples, practice, and flashcards.

01

Asymptotic Analysis

Big-O, Θ and Ω comparisons are asked almost every year: learn the definitions, the growth-rate ladder, the limit test, and how to turn nested loops into sums — then rank functions in seconds.

~3 hrs ~1–1.5 marks High
02

Sorting & Searching

Know every sort by its best/average/worst time, extra space, stability and in-place status, and recall the decision-tree lower bound — these properties drive nearly every sorting MCQ.

~4 hrs ~1.5–2 marks Must-score
03

Divide & Conquer

Divide and conquer questions are recurrence-solving questions: recognise the form T(n) = aT(n/b) + f(n), compare n^(log_b a) with f(n), and read off the answer — then handle the odd recurrences by recursion tree.

~4 hrs ~0.5–1 marks High
04

Greedy Algorithms

Greedy questions test whether you can recognise the correct greedy criterion, run it by hand (activity selection, Huffman, MST, job sequencing), and know exactly when greedy gives a wrong answer.

~4 hrs ~1–1.5 marks High
05

Dynamic Programming

DP questions ask for a recurrence, a table value, or a time/space bound. Learn the standard recurrences (knapsack, LCS, matrix chain, rod cutting, coin change) and practise filling small tables quickly.

~5 hrs ~1.5–2 marks Must-score
06

Graph Algorithms

Graph algorithms are the highest-yield part of Algorithms: know BFS/DFS properties, when each shortest-path algorithm applies, every complexity, and how to run Dijkstra and Kruskal by hand.

~5 hrs ~2–3 marks Must-score
07

Complexity Classes

Complexity questions are definition and recognition questions: know P, NP, NP-hard and NP-complete precisely, the direction of a reduction, the consequences of P = NP, and which classic problems are NP-complete versus easy.

~3 hrs ~0.5–1 marks Moderate

Suggested study order

  1. Asymptotic Analysis → Sorting & Searching
  2. Divide & Conquer
  3. Greedy Algorithms → Dynamic Programming
  4. Graph Algorithms → Complexity Classes

After each topic, solve previous-year Algorithms questions for that unit. Keep a one-page sheet of Master-theorem cases, sort complexities/stability, classic DP recurrences, and graph algorithm applicability (negative edges, DAG, MST).

Frequently asked questions

Which algorithms are must-know for GATE?

Asymptotics, sorting, searching, BFS/DFS, Dijkstra, MST (Kruskal/Prim), greedy patterns, and basic DP recurrences. Open each subtopic from this hub for a full lesson.

Do I need to code algorithms in the exam?

No. Identify the algorithm, compute complexity or a short result, and reason about correctness at MCQ level.

How to study DP for GATE?

Learn classic patterns (knapsack, LCS, matrix chain style recurrences) and practise recognising overlapping subproblems in stems.

What should I revise in the last month?

Sort complexities and stability, Master-theorem cases, activity selection/Huffman, 0/1 knapsack and LCS tables, Dijkstra vs Bellman-Ford vs Floyd, and Kruskal/Prim. Re-solve recent PYQs under timed conditions.

Related resources