650 PYQs from 10 papers
    GATE CS Chapter-wise PYQs: 650 Previous Year Questions with Solutions (2021 to 2026)

    650 GATE CS previous year questions from 10 papers (2021 to 2026), sorted chapter-wise across 88 chapters with answers and step-by-step solutions.

    Jump to a past paper

    Why Practice PYQs?

    Chapter-wise Classification

    Questions organized by chapters for focused topic-wise practice

    Hints & Solutions

    Every question has step-by-step solution with helpful hints

    Practice Mode

    Learn at your pace - see solutions immediately after attempting

    Exam Mode

    Simulate real exam - timed test with solutions at the end

    GATE CS Chapter-wise PYQs: 650 Previous Year Questions with Solutions (2021 to 2026)

    650 GATE CS previous year questions from 10 papers (2021 to 2026), sorted chapter-wise across 88 chapters with answers and step-by-step solutions.

    GATE CS Past Papers Archive by Year and Slot

    Engineering Mathematics: Previous year questions

    UnitChaptersPrevious year questions
    Discrete Mathematics747
    Linear Algebra420
    Calculus313
    Probability and Statistics525

    Quantitative Aptitude: Previous year questions

    UnitChaptersPrevious year questions
    Numerical computation and estimation428
    Data interpretation25

    Analytical Aptitude: Previous year questions

    UnitChaptersPrevious year questions
    Logic421

    Digital Logic: Previous year questions

    UnitChaptersPrevious year questions
    Digital Logic433

    Computer Organization and Architecture: Previous year questions

    UnitChaptersPrevious year questions
    Computer Organization and Architecture666

    Verbal Aptitude: Previous year questions

    UnitChaptersPrevious year questions
    Basic English grammar310
    Basic vocabulary311

    Programming and Data Structures: Previous year questions

    UnitChaptersPrevious year questions
    Programming and Data Structures766

    Spatial Aptitude: Previous year questions

    UnitChaptersPrevious year questions
    Transformation of shapes519

    Algorithms: Previous year questions

    UnitChaptersPrevious year questions
    Algorithms547

    Theory of Computation: Previous year questions

    UnitChaptersPrevious year questions
    Theory of Computation447

    Compiler Design: Previous year questions

    UnitChaptersPrevious year questions
    Compiler Design643

    Operating System: Previous year questions

    UnitChaptersPrevious year questions
    Operating System548

    Databases: Previous year questions

    UnitChaptersPrevious year questions
    Databases548

    Computer Networks: Previous year questions

    UnitChaptersPrevious year questions
    Computer Networks653

    GATE CS Chapter-wise Previous Year Questions (PYQs) 2026

    Engineering Mathematics Past Year Questions

    Discrete Mathematics

    Linear Algebra

    Calculus

    Probability and Statistics

    Quantitative Aptitude Past Year Questions

    Numerical computation and estimation

    Data interpretation

    Analytical Aptitude Past Year Questions

    Logic

    Digital Logic Past Year Questions

    Digital Logic

    Verbal Aptitude Past Year Questions

    Basic English grammar

    Basic vocabulary

    Computer Organization and Architecture Past Year Questions

    Computer Organization and Architecture

    Programming and Data Structures Past Year Questions

    Programming and Data Structures

    Spatial Aptitude Past Year Questions

    Transformation of shapes

    Algorithms Past Year Questions

    Algorithms

    Theory of Computation Past Year Questions

    Theory of Computation

    Compiler Design Past Year Questions

    Compiler Design

    Operating System Past Year Questions

    Operating System

    Databases Past Year Questions

    Databases

    Computer Networks Past Year Questions

    Computer Networks

    GATE CS Previous Year Questions with Solutions

    Engineering Mathematics: Solved PYQs

    Q1. (CAT 2024_Set2) Let \(Z_n\) be the group of integers \(\{0,1,2,\ldots,n-1\}\) with addition modulo \(n\) as the group operation. The number of elements in the group \(Z_2\times Z_3\times Z_4\) that are their own inverses is __________

    Answer: 4.00

    Solution: Insight: In a direct product of groups, an element is its own inverse if and only if each of its components is its own inverse in the respective factor group.
    Exam route: For $Z_n$ under addition, an element $x$ is its own inverse if $x + x \equiv 0 \pmod n \implies 2x \equiv 0 \pmod n$. Count the solutions for $n=2, 3, 4$ independently and multiply them.
    Learning route:
    1. The group is $Z_2 \times Z_3 \times Z_4$ under component-wise addition modulo $n$. The identity is $(0,0,0)$.
    2. An element $(x, y, z)$ is its own inverse if $(x, y, z) + (x, y, z) = (0, 0, 0)$, which means $2x \equiv 0 \pmod 2$, $2y \equiv 0 \pmod 3$, and $2z \equiv 0 \pmod 4$.
    3. In $Z_2$: $2x \equiv 0 \pmod 2$ is satisfied by $x \in \{0, 1\}$. Count = 2.
    4. In $Z_3$: $2y \equiv 0 \pmod 3$ is satisfied only by $y = 0$ (since $\gcd(2,3)=1$). Count = 1.
    5. In $Z_4$: $2z \equiv 0 \pmod 4$ is satisfied by $z \in \{0, 2\}$. Count = 2.
    6. Total number of self-inverse elements = $2 \times 1 \times 2 = 4$.
    Common trap: Assuming only the identity element is self-inverse. This is true for odd-order cyclic groups, but for even-order cyclic groups, the element $n/2$ is also its own inverse.

    Q2. (CAT 2022) A box contains five balls of same size and shape. Three of them are green coloured balls and two of them are orange coloured balls. Balls are drawn from the box one at a time. If a green ball is drawn, it is not replaced. If an orange ball is drawn, it is replaced with another orange ball.<br/><br/>First ball is drawn. What is the probability of getting an orange ball in the next draw?

    1. \(\dfrac{1}{2}\)
    2. \(\dfrac{8}{25}\)
    3. \(\dfrac{19}{50}\)
    4. \(\dfrac{23}{50}\)

    Answer: D

    Solution: Insight: This is an asymmetric replacement problem requiring the Law of Total Probability over the unknown first draw.
    Exam route: Branch into two paths: 1st is Green (prob 3/5, new state 2G, 2O) and 1st is Orange (prob 2/5, new state 3G, 2O). Multiply and sum the path probabilities.
    Learning route:
    Step 1: Identify initial state: 3 Green (G), 2 Orange (O). Total = 5.
    Step 2: Define the two mutually exclusive paths for the first draw.
    Path A: First ball is Green.
    - Probability of Path A: P(1st G) = 3/5.
    - Rule: Green is not replaced. New state: 2 G, 2 O. Total = 4.
    - Probability of 2nd Orange given Path A: P(2nd O | 1st G) = 2/4 = 1/2.
    - Joint probability of Path A: (3/5) * (1/2) = 3/10 = 15/50.
    Path B: First ball is Orange.
    - Probability of Path B: P(1st O) = 2/5.
    - Rule: Orange is replaced with another Orange. The drawn orange is removed, but another is added, so the count of Orange remains 2, and total remains 5. New state: 3 G, 2 O. Total = 5.
    - Probability of 2nd Orange given Path B: P(2nd O | 1st O) = 2/5.
    - Joint probability of Path B: (2/5) * (2/5) = 4/25 = 8/50.
    Step 3: Apply the Law of Total Probability.
    P(2nd O) = P(Path A) + P(Path B) = 15/50 + 8/50 = 23/50.
    Verification: The sum of all path probabilities for the second draw must equal 1. P(2nd G) = (3/5 * 2/4) + (2/5 * 3/5) = 15/50 + 12/50 = 27/50. Total = 23/50 + 27/50 = 1. The math is perfectly consistent.

    Q3. (CAT 2024_Set2) Let \(p\) and \(q\) be the following propositions:<br/><br/>\(p\): Fail grade can be given.<br/>\(q\): Student scores more than 50% marks.<br/><br/>Consider the statement: “Fail grade cannot be given when student scores more than 50% marks.”<br/><br/>Which one of the following is the CORRECT representation of the above statement in propositional logic?

    1. \(q \rightarrow \neg p\)
    2. \(q \rightarrow p\)
    3. \(p \rightarrow q\)
    4. \(\neg p \rightarrow q\)

    Answer: A

    Solution: Key idea: This is a propositional translation question, recognizable because it asks to convert an English sentence with conditional keywords into a logical formula.
    Step 1: Identify the atomic propositions.
    $p$: Fail grade can be given.
    $q$: Student scores more than 50% marks.
    Step 2: Translate the conditional statement.
    The statement is: "Fail grade cannot be given when student scores more than 50% marks."
    The word "when" acts as "if". So, "If student scores more than 50% marks, then fail grade cannot be given."
    This translates to: If $q$, then $\neg p$.
    In propositional logic, this is written as $q \rightarrow \neg p$.
    Step 3: Match with the options.
    Option A matches $q \rightarrow \neg p$.
    Answer: A

    Q4. (CAT 2025_Set1) A fair six-faced dice, with the faces labelled ‘1’, ‘2’, ‘3’, ‘4’, ‘5’, and ‘6’, is rolled thrice. What is the probability of rolling ‘6’ exactly once?

    1. \(\frac{75}{216}\)
    2. \(\frac{1}{6}\)
    3. \(\frac{1}{18}\)
    4. \(\frac{25}{216}\)

    Answer: A

    Solution: Key idea: This is a Binomial Probability problem, recognizable because we have a fixed number of independent trials (rolling the die 3 times) and we are looking for a specific number of successes (rolling a '6').

    Step 1: Identify the parameters of the Bernoulli trial.
    - Total trials ($n$) = 3.
    - Success event: Rolling a '6'.
    - Probability of success ($p$) = $\frac{1}{6}$.
    - Probability of failure ($q$) = $1 - p = \frac{5}{6}$.
    - Desired number of successes ($k$) = 1.

    Step 2: Apply the Binomial Probability Formula.
    The probability of getting exactly $k$ successes in $n$ trials is:
    $$ P(X=k) = \binom{n}{k} p^k q^{n-k} $$

    Step 3: Substitute the values and calculate.
    $$ P(X=1) = \binom{3}{1} \left(\frac{1}{6}\right)^1 \left(\frac{5}{6}\right)^{3-1} $$
    $$ P(X=1) = 3 \times \frac{1}{6} \times \left(\frac{5}{6}\right)^2 $$
    $$ P(X=1) = 3 \times \frac{1}{6} \times \frac{25}{36} = \frac{75}{216} $$

    Answer: $\frac{75}{216}$

    Q5. (CAT 2026_Set2) For two different persons \(x\) and \(y\), the predicate \(M(x,y)\) denotes that x knows y. Consider the following statement.<br/><br/><i>There is a person who does not know anyone else, but that person is known by everyone else.</i><br/><br/>Which one of the following expressions represents the above statement?

    1. \((\exists y)(\forall x)\ ((x \ne y) \rightarrow (M(x,y) \land \neg M(y,x)))\)
    2. \((\forall y)(\exists x)\ ((x \ne y) \rightarrow (M(x,y) \land \neg M(y,x)))\)
    3. \((\exists y)(\exists x)\ ((x \ne y) \rightarrow (M(x,y) \land \neg M(y,x)))\)
    4. \((\forall y)(\forall x)\ ((x \ne y) \rightarrow (M(x,y) \land \neg M(y,x)))\)

    Answer: A

    Solution: Key idea: This is a nested quantifier translation question, recognizable because it describes a specific relational property ("knows") among a domain of people using phrases like "There is a person" and "everyone else".
    Step 1: Identify the core components.
    "There is a person" $\rightarrow \exists y$. Let this person be $y$.
    "who does not know anyone else" $\rightarrow$ For all $x \neq y$, $y$ does not know $x$. This is $\neg M(y,x)$.
    "but that person is known by everyone else" $\rightarrow$ For all $x \neq y$, $x$ knows $y$. This is $M(x,y)$.
    Step 2: Combine the conditions for "everyone else".
    For any $x$, if $x \neq y$, then both conditions must hold: $M(x,y) \land \neg M(y,x)$.
    This translates to: $\forall x ((x \neq y) \rightarrow (M(x,y) \land \neg M(y,x)))$.
    Step 3: Attach the outer quantifier.
    "There is a person $y$" wraps around the above:
    $\exists y \forall x ((x \neq y) \rightarrow (M(x,y) \land \neg M(y,x)))$.
    Step 4: Match with options.
    Option A matches this exactly.
    Answer: A

    Quantitative Aptitude: Solved PYQs

    Q1. (CAT 2024_Set1) The number of coins of ₹1, ₹5, and ₹10 denominations that a person has are in the ratio \(5:3:13\). Of the total amount, the percentage of money in ₹5 coins is

    1. \(21\%\)
    2. \(14\frac{2}{7}\%\)
    3. \(10\%\)
    4. \(30\%\)

    Answer: C

    Solution: Insight: The ratio given is of the *number of coins*, not their monetary value. You must convert the count ratio into a value ratio by multiplying each part by its denomination.
    Exam route: Let the number of coins be $5k, 3k, 13k$. Their values are $5k \times 1 = 5k$, $3k \times 5 = 15k$, and $13k \times 10 = 130k$. Total value $= 5k + 15k + 130k = 150k$. The percentage in ₹5 coins is $\frac{15k}{150k} \times 100 = 10\%$.
    Learning route:
    Step 1: Assign the multiplier $k$. The number of ₹1, ₹5, and ₹10 coins are $5k, 3k$, and $13k$ respectively.
    Step 2: Convert the number ratio into a value ratio by multiplying each count by its denomination.
    - Value of ₹1 coins $= 5k \times 1 = 5k$
    - Value of ₹5 coins $= 3k \times 5 = 15k$
    - Value of ₹10 coins $= 13k \times 10 = 130k$
    Step 3: Total amount $= 5k + 15k + 130k = 150k$.
    Step 4: Required percentage $= \frac{15k}{150k} \times 100 = 10\%$.
    Trap warning: Option B ($14\frac{2}{7}\%$) comes from taking $\frac{3}{5+3+13} = \frac{3}{21}$, which is the ratio of the *number* of ₹5 coins to the total number of coins. The question asks for the percentage of the *amount*, not the count.
    Verification: If $k=1$, coins are 5, 3, 13; values are ₹5, ₹15, ₹130; total ₹150; ₹15 is exactly 10%.

    Q2. (CAT 2024_Set2) The pie charts depict the shares of various power generation technologies in the total electricity generation of a country for the years 2007 and 2023.<br/><br/><svg width="600" height="280" viewBox="0 0 600 280" xmlns="http://www.w3.org/2000/svg"><rect width="600" height="280" fill="white"/><text x="105" y="25" font-size="20" font-weight="bold" text-anchor="middle">Year</text><text x="105" y="48" font-size="20" font-weight="bold" text-anchor="middle">2007</text><text x="475" y="25" font-size="20" font-weight="bold" text-anchor="middle">Year</text><text x="475" y="48" font-size="20" font-weight="bold" text-anchor="middle">2023</text><path d="M150 130 L150 50 A80 80 0 0 1 214.72 177.02 Z" fill="#b7c9e8" stroke="black"/><path d="M150 130 L214.72 177.02 A80 80 0 0 1 102.98 194.72 Z" fill="#f4c6a7" stroke="black"/><path d="M150 130 L102.98 194.72 A80 80 0 0 1 85.28 177.02 Z" fill="#dddddd" stroke="black"/><path d="M150 130 L85.28 177.02 A80 80 0 0 1 125.28 53.92 Z" fill="#f8df91" stroke="black"/><path d="M150 130 L125.28 53.92 A80 80 0 0 1 150 50 Z" fill="#f6c1c1" stroke="black"/><text x="181" y="113" font-size="14" font-weight="bold" text-anchor="middle">Coal</text><text x="181" y="130" font-size="14" font-weight="bold" text-anchor="middle">35%</text><text x="154" y="166" font-size="14" font-weight="bold" text-anchor="middle">Gas</text><text x="154" y="183" font-size="14" font-weight="bold" text-anchor="middle">25%</text><text x="111" y="120" font-size="14" font-weight="bold" text-anchor="middle">Hydro</text><text x="111" y="137" font-size="14" font-weight="bold" text-anchor="middle">30%</text><line x1="132" y1="62" x2="122" y2="31" stroke="black"/><text x="120" y="15" font-size="13" font-weight="bold" text-anchor="middle">Solar 5%</text><line x1="94" y1="185" x2="63" y2="215" stroke="black"/><text x="52" y="225" font-size="13" font-weight="bold" text-anchor="middle">Wind</text><text x="52" y="241" font-size="13" font-weight="bold" text-anchor="middle">5%</text><path d="M430 130 L430 50 A80 80 0 0 1 506.08 105.28 Z" fill="#b7c9e8" stroke="black"/><path d="M430 130 L506.08 105.28 A80 80 0 0 1 494.72 177.02 Z" fill="#f4c6a7" stroke="black"/><path d="M430 130 L494.72 177.02 A80 80 0 0 1 454.72 206.08 Z" fill="#dddddd" stroke="black"/><path d="M430 130 L454.72 206.08 A80 80 0 0 1 353.92 105.28 Z" fill="#f8df91" stroke="black"/><path d="M430 130 L353.92 105.28 A80 80 0 0 1 430 50 Z" fill="#f6c1c1" stroke="black"/><text x="461" y="93" font-size="14" font-weight="bold" text-anchor="middle">Coal</text><text x="461" y="110" font-size="14" font-weight="bold" text-anchor="middle">20%</text><text x="478" y="134" font-size="14" font-weight="bold" text-anchor="middle">Gas</text><text x="478" y="151" font-size="14" font-weight="bold" text-anchor="middle">15%</text><text x="400" y="163" font-size="14" font-weight="bold" text-anchor="middle">Hydro</text><text x="400" y="180" font-size="14" font-weight="bold" text-anchor="middle">35%</text><text x="394" y="88" font-size="14" font-weight="bold" text-anchor="middle">Solar</text><text x="394" y="105" font-size="14" font-weight="bold" text-anchor="middle">20%</text><line x1="472" y1="188" x2="519" y2="222" stroke="black"/><text x="535" y="226" font-size="13" font-weight="bold" text-anchor="middle">Wind</text><text x="535" y="242" font-size="13" font-weight="bold" text-anchor="middle">10%</text></svg><br/><br/>The renewable sources of electricity generation consist of Hydro, Solar and Wind. Assuming that the total electricity generated remains the same from 2007 to 2023, what is the percentage increase in the share of the renewable sources of electricity generation over this period?

    1. 25%
    2. 50%
    3. 77.5%
    4. 62.5%

    Answer: D

    Solution: Insight: Since total electricity generated remains constant across both years, percentage shares can be used directly in the percentage change formula without converting to absolute values.
    Exam route: Sum the renewable percentages for each year, then apply (new − old)/old × 100.
    Learning route:
    Step 1: Identify renewable sources from the question statement: Hydro, Solar, and Wind.
    Step 2: Sum renewable share for 2007 from the pie chart: Hydro 30% + Solar 5% + Wind 5% = 40%.
    Step 3: Sum renewable share for 2023 from the pie chart: Hydro 35% + Solar 20% + Wind 10% = 65%.
    Step 4: Since total generation is constant, the percentage increase in share equals the percentage increase in actual generation. The old value is the anchor denominator.
    Step 5: Apply the percentage change formula:
    $$ \text{Percentage Change} = \left(\frac{65 - 40}{40}\right) \times 100 = \frac{25}{40} \times 100 = 62.5\% $$
    Verification: If total generation = 100 units, renewables went from 40 to 65 units. $(65 - 40)/40 = 0.625 = 62.5\%$. ✓

    Q3. (CAT 2021_Set1) <table> <tr> <th>Items</th> <th>Cost<br/>(₹)</th> <th>Profit %</th> <th>Marked Price<br/>(₹)</th> </tr> <tr> <td>P</td> <td>5,400</td> <td>---</td> <td>5,860</td> </tr> <tr> <td>Q</td> <td>---</td> <td>25</td> <td>10,000</td> </tr> </table><br/>Details of prices of two items P and Q are presented in the above table. The ratio of cost of item P to cost of item Q is 3:4. Discount is calculated as the difference between the marked price and the selling price. The profit percentage is calculated as the ratio of the difference between selling price and cost, to the cost \(\left(\text{Profit \%}=\frac{\text{Selling price}-\text{Cost}}{\text{Cost}}\times 100\right)\).<br/><br/>The discount on item Q, as a percentage of its marked price, is ______

    1. 25
    2. 12.5
    3. 10
    4. 5

    Answer: C

    Solution: Insight: The cost price of Q can be derived from the given ratio with P's cost price, then selling price follows from the profit percentage, and finally the discount percentage is calculated from the marked price.
    Exam route: CP_Q = 5400 * (4/3) = 7200. SP_Q = 7200 * 1.25 = 9000. Discount = 10000 - 9000 = 1000. Discount % = (1000 / 10000) * 100 = 10%.
    Learning route:
    1. Identify knowns: CP_P = 5400, and the ratio CP_P : CP_Q = 3 : 4.
    2. Calculate CP_Q: Since 3 parts = 5400, 1 part = 1800. Thus, CP_Q = 4 * 1800 = 7200.
    3. Use Profit % for Q (25%) to find SP_Q: SP_Q = CP_Q * (1 + 25/100) = 7200 * 1.25 = 9000.
    4. Use MP_Q (10000) to find the absolute Discount: Discount = MP_Q - SP_Q = 10000 - 9000 = 1000.
    5. Calculate Discount %: The base for discount percentage is always the Marked Price. So, (1000 / 10000) * 100 = 10%.

    Q4. (CAT 2021_Set2) <svg xmlns="http://www.w3.org/2000/svg" width="650" height="400" viewBox="0 0 650 400"> <defs> <pattern id="diagonalHatch" patternUnits="userSpaceOnUse" width="10" height="10" patternTransform="rotate(135)"> <line x1="0" y1="0" x2="0" y2="10" stroke="black" stroke-width="4"/> </pattern> </defs> <rect x="65" y="20" width="550" height="290" fill="white" stroke="black" stroke-width="2"/> <line x1="65" y1="310" x2="615" y2="310" stroke="black" stroke-width="2"/> <line x1="65" y1="20" x2="65" y2="310" stroke="black" stroke-width="2"/> <text x="37" y="316" font-size="18">0</text> <text x="27" y="274" font-size="18">50</text> <text x="18" y="232" font-size="18">100</text> <text x="18" y="190" font-size="18">150</text> <text x="18" y="148" font-size="18">200</text> <text x="18" y="106" font-size="18">250</text> <text x="18" y="64" font-size="18">300</text> <text x="18" y="27" font-size="18">350</text> <rect x="95" y="227" width="65" height="83" fill="url(#diagonalHatch)" stroke="black" stroke-width="2"/> <rect x="160" y="111" width="65" height="199" fill="black" stroke="black" stroke-width="2"/> <rect x="275" y="144" width="65" height="166" fill="url(#diagonalHatch)" stroke="black" stroke-width="2"/> <rect x="340" y="65" width="65" height="245" fill="black" stroke="black" stroke-width="2"/> <rect x="455" y="61" width="65" height="249" fill="url(#diagonalHatch)" stroke="black" stroke-width="2"/> <rect x="520" y="136" width="65" height="174" fill="black" stroke="black" stroke-width="2"/> <text x="111" y="217" font-size="19" font-weight="bold">100</text> <text x="177" y="101" font-size="19" font-weight="bold">240</text> <text x="292" y="134" font-size="19" font-weight="bold">200</text> <text x="357" y="55" font-size="19" font-weight="bold">296</text> <text x="472" y="51" font-size="19" font-weight="bold">300</text> <text x="537" y="126" font-size="19" font-weight="bold">210</text> <text x="111" y="340" font-size="22" font-weight="bold">Year 1</text> <text x="291" y="340" font-size="22" font-weight="bold">Year 2</text> <text x="471" y="340" font-size="22" font-weight="bold">Year 3</text> <rect x="185" y="365" width="12" height="12" fill="url(#diagonalHatch)" stroke="black"/> <text x="202" y="377" font-size="18">Number of units</text> <rect x="365" y="365" width="12" height="12" fill="black" stroke="black"/> <text x="382" y="377" font-size="18">Net Profit (₹)</text> </svg><br/>The number of units of a product sold in three different years and the respective net profits are presented in the figure above. The cost/unit in Year 3 was ₹ 1, which was half the cost/unit in Year 2. The cost/unit in Year 3 was one-third of the cost/unit in Year 1. Taxes were paid on the selling price at 10%, 13% and 15% respectively for the three years. Net profit is calculated as the difference between the selling price and the sum of cost and taxes paid in that year.<br/><br/>The ratio of the selling price in Year 2 to the selling price in Year 3 is ________.

    1. 4:3
    2. 1:1
    3. 3:4
    4. 1:2

    Answer: A

    Solution: Insight: Net Profit = Selling Price − Cost − Tax, where Tax is a percentage of Selling Price. Rearranging gives SP = (Net Profit + Cost) / (1 − tax rate).
    Exam route: Extract units sold and profits from the bar chart, compute costs from the given cost/unit relationships, solve for SP₂ and SP₃, then simplify their ratio.
    Learning route:
    Step 1: Extract data from the bar chart labels:
    - Year 1: 100 units sold, ₹240 net profit
    - Year 2: 200 units sold, ₹296 net profit
    - Year 3: 300 units sold, ₹210 net profit
    Step 2: Determine cost/unit for each year from the problem statement:
    - Year 3 cost/unit = ₹1
    - Year 2 cost/unit = ₹2 (since Year 3 is half of Year 2)
    - Year 1 cost/unit = ₹3 (since Year 3 is one-third of Year 1)
    Step 3: Calculate total cost for Years 2 and 3:
    - Cost₂ = 200 units × ₹2 = ₹400
    - Cost₃ = 300 units × ₹1 = ₹300
    Step 4: Set up the net profit equation. Tax is on selling price, so:
    $$ \text{Net Profit} = SP - \text{Cost} - (\text{tax rate} \times SP) = SP(1 - \text{tax rate}) - \text{Cost} $$
    Step 5: Rearrange to solve for SP:
    $$ SP = \frac{\text{Net Profit} + \text{Cost}}{1 - \text{tax rate}} $$
    Step 6: Calculate SP₂ with 13% tax:
    $$ SP_2 = \frac{296 + 400}{1 - 0.13} = \frac{696}{0.87} = ₹800 $$
    Step 7: Calculate SP₃ with 15% tax:
    $$ SP_3 = \frac{210 + 300}{1 - 0.15} = \frac{510}{0.85} = ₹600 $$
    Step 8: Find the required ratio SP₂ : SP₃ = 800 : 600 = 4 : 3.
    Verification: Year 2: SP=800, Tax=13%×800=104, Cost=400, Profit=800−104−400=296 ✓. Year 3: SP=600, Tax=15%×600=90, Cost=300, Profit=600−90−300=210 ✓.

    Q5. (CAT 2021_Set2) If \(\theta\) is the angle, in degrees, between the longest diagonal of the cube and any one of the edges of the cube, then, \(\cos \theta =\)

    1. \(\frac{1}{2}\)
    2. \(\frac{1}{\sqrt{3}}\)
    3. \(\frac{1}{\sqrt{2}}\)
    4. \(\frac{\sqrt{3}}{2}\)

    Answer: B

    Solution: Insight: The angle between a cube's body diagonal and any of its edges is a constant, independent of the cube's size.
    Exam route: Recall the standard formula for a cube: \(\cos\theta = \frac{1}{\sqrt{3}}\).
    Learning route:
    1. Let the cube have edge length \(a\).
    2. The body diagonal stretches from one corner to the opposite corner through the interior. Its length is \(d = \sqrt{a^2 + a^2 + a^2} = a\sqrt{3}\).
    3. The angle \(\theta\) between the body diagonal and an edge forms a right triangle where the edge is the adjacent side (length \(a\)) and the body diagonal is the hypotenuse (length \(a\sqrt{3}\)).
    4. Therefore, \(\cos\theta = \frac{\text{adjacent}}{\text{hypotenuse}} = \frac{a}{a\sqrt{3}} = \frac{1}{\sqrt{3}}\).
    Wrong path: Confusing the body diagonal with a face diagonal. A face diagonal has length \(a\sqrt{2}\), which would give \(\cos\theta = \frac{1}{\sqrt{2}}\) (Option C). This is incorrect because the question specifies the "longest diagonal".

    Analytical Aptitude: Solved PYQs

    Q1. (CAT 2026_Set2) Figures (i) and (ii) represent intercity highway systems. The black dots represent cities and the line segments between them represent intercity highways.<br/>A salesperson needs to make a trip. She needs to start from a city, visit each of the remaining cities exactly once, and finally return to the same city from which she started.<br/><br/>Which one of the following options is then true?<br/> <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 700 300" width="700" height="300" role="img" aria-label="Two intercity highway system graphs"> <rect x="0" y="0" width="700" height="300" fill="white"/> <text x="175" y="25" font-size="22" font-weight="bold" text-anchor="middle" fill="black">(i)</text> <text x="500" y="25" font-size="22" font-weight="bold" text-anchor="middle" fill="black">(ii)</text> <g stroke="black" stroke-width="3" fill="none"> <line x1="70" y1="55" x2="280" y2="55"/> <line x1="70" y1="125" x2="280" y2="125"/> <line x1="70" y1="195" x2="280" y2="195"/> <line x1="70" y1="265" x2="280" y2="265"/> <line x1="70" y1="55" x2="70" y2="265"/> <line x1="140" y1="55" x2="140" y2="265"/> <line x1="210" y1="55" x2="210" y2="265"/> <line x1="280" y1="55" x2="280" y2="265"/> </g> <g fill="black"> <circle cx="70" cy="55" r="7"/> <circle cx="140" cy="55" r="7"/> <circle cx="210" cy="55" r="7"/> <circle cx="280" cy="55" r="7"/> <circle cx="70" cy="125" r="7"/> <circle cx="140" cy="125" r="7"/> <circle cx="210" cy="125" r="7"/> <circle cx="280" cy="125" r="7"/> <circle cx="70" cy="195" r="7"/> <circle cx="140" cy="195" r="7"/> <circle cx="210" cy="195" r="7"/> <circle cx="280" cy="195" r="7"/> <circle cx="70" cy="265" r="7"/> <circle cx="140" cy="265" r="7"/> <circle cx="210" cy="265" r="7"/> <circle cx="280" cy="265" r="7"/> </g> <g stroke="black" stroke-width="3" fill="none"> <line x1="420" y1="50" x2="610" y2="50"/> <line x1="420" y1="50" x2="390" y2="180"/> <line x1="390" y1="180" x2="500" y2="235"/> <line x1="500" y1="235" x2="610" y2="50"/> <line x1="420" y1="50" x2="525" y2="95"/> <line x1="525" y1="95" x2="500" y2="235"/> </g> <g fill="black"> <circle cx="420" cy="50" r="7"/> <circle cx="610" cy="50" r="7"/> <circle cx="390" cy="180" r="7"/> <circle cx="500" cy="235" r="7"/> <circle cx="525" cy="95" r="7"/> </g> </svg>

    1. Such a trip is possible for (i), but not for (ii).
    2. Such a trip is possible for (ii), but not for (i).
    3. Such a trip is possible for both (i) and (ii).
    4. Such a trip is possible neither for (i) nor for (ii).

    Answer: A

    Solution: Insight: A Hamiltonian cycle requires every vertex to have a degree of exactly 2 within the cycle. Graph (ii) has three vertices of degree 2, which forces a contradiction at the central vertex. Graph (i) is a 4x4 grid, which is bipartite with equal partitions, allowing a valid cycle.
    Exam route: For (ii), identify vertices with degree 2. Their incident edges must be in the cycle. This forces the central vertex to have degree 3 in the cycle, which is impossible. Thus, (ii) has no Hamiltonian cycle. For (i), a 4x4 grid has a known Hamiltonian cycle (e.g., a snake pattern that closes). Thus, (i) is possible, (ii) is not.
    Learning route:
    1. Understand the goal: A trip visiting every city exactly once and returning to the start is a Hamiltonian cycle.
    2. Analyze Graph (ii): It has 5 vertices. The top-left, bottom, and top-right vertices each have exactly 2 connections (degree 2).
    3. Apply the Degree-Two Vertex Rule: In any Hamiltonian cycle, if a vertex has degree 2, both of its edges must be part of the cycle.
    4. Trace the forced edges in (ii): The three degree-2 vertices force 6 edges. However, these edges all converge on the central vertex, giving it a degree of 3 in the supposed cycle. A cycle can only have degree 2 for every vertex. This is a contradiction, so (ii) is impossible.
    5. Analyze Graph (i): It is a 4x4 grid graph. It is bipartite with 8 black and 8 white vertices. Since the partitions are equal, a Hamiltonian cycle is possible. We can explicitly construct one by tracing the perimeter and weaving through the center without repeating vertices.
    6. Conclusion: Possible for (i), not for (ii).

    Q2. (CAT 2025_Set2) If IMAGE and FIELD are coded as FHBNJ and EMFJG respectively then, which one among the given options is the most appropriate code for BEACH ?

    1. CEADP
    2. IDBFC
    3. JGIBC
    4. IBCEC

    Answer: B

    Solution: Insight: The coding rule involves reversing the original word and then applying a uniform forward shift of +1 to each letter.
    Exam route: Reverse BEACH to get HCAEB. Shift each letter forward by 1: H→I, C→D, A→B, E→F, B→C. Result is IDBFC.
    Learning route:
    Step 1: Test direct left-to-right shift for IMAGE → FHBNJ. I(9) to F(6) is -3, M(13) to H(8) is -5. Inconsistent.
    Step 2: Apply the Reverse Test. Reverse IMAGE to get EGAMI.
    Step 3: Calculate shift: E(5)→F(6) [+1], G(7)→H(8) [+1], A(1)→B(2) [+1], M(13)→N(14) [+1], I(9)→J(10) [+1]. The rule is confirmed: Reverse +1.
    Step 4: Verify with FIELD. Reverse to DLEIF. Shift +1: D→E, L→M, E→F, I→J, F→G. Result EMFJG. Matches perfectly.
    Step 5: Apply to BEACH. Reverse to HCAEB. Shift +1: H→I, C→D, A→B, E→F, B→C. Final code is IDBFC.

    Q3. (CAT 2021_Set1) _____ is to <i>surgery</i> as <i>writer</i> is to ________<br/><br/>Which one of the following options maintains a similar logical relation in the above sentence?

    1. Plan, outline
    2. Hospital, library
    3. Doctor, book
    4. Medicine, grammar

    Answer: C

    Solution: Insight: This is a Worker-to-Product/Action analogy. The logical relationship is "A [Professional] performs/produces [Action/Product]".
    Exam route: A Writer produces a Book. Following the same directional relationship, a Doctor performs Surgery. Therefore, the missing pair is Doctor, book.
    Learning route:
    Step 1: Isolate the known contiguous pair: "writer" and the blank. We know a writer's primary output is a "book".
    Step 2: Formulate the Bridge Sentence: "A [Worker] produces/performs [Product/Action]".
    Step 3: Apply to the first part: "A [Worker] performs surgery". The professional who performs surgery is a "Doctor".
    Step 4: Verify directionality. Doctor $\rightarrow$ Surgery (Worker $\rightarrow$ Action). Writer $\rightarrow$ Book (Worker $\rightarrow$ Product). The logical relation is perfectly maintained.

    Q4. (CAT 2024_Set2) In the sequence \(6, 9, 14, x, 30, 41\), a possible value of \(x\) is

    1. 25
    2. 21
    3. 18
    4. 20

    Answer: B

    Solution: Insight: This is a second-order difference sequence where the first differences form a progression of consecutive odd numbers.
    Exam route: Calculate first differences: $9-6=3$, $14-9=5$, and $41-30=11$. The missing differences between 5 and 11 in an odd number sequence are 7 and 9. Thus, $x = 14 + 7 = 21$. Verify: $21 + 9 = 30$.
    Learning route:
    Step 1: Calculate the first differences ($\Delta_1$) between consecutive terms:
    $9 - 6 = 3$
    $14 - 9 = 5$
    $x - 14 = ?$
    $30 - x = ?$
    $41 - 30 = 11$
    Step 2: Analyze the known differences: $3, 5, \dots, 11$. This strongly suggests a sequence of consecutive odd numbers: $3, 5, 7, 9, 11$.
    Step 3: Solve for the missing terms using this pattern. Assume the next difference is $7$:
    $x = 14 + 7 = 21$
    Step 4: Verify with the next term. If $x = 21$, then the next difference is $30 - 21 = 9$. This perfectly matches the expected odd number $9$.
    Conclusion: $x = 21$.

    Q5. (CAT 2023) A survey for a certain year found that 90% of pregnant women received medical care at least once before giving birth. Of these women, 60% received medical care from doctors, while 40% received medical care from other healthcare providers.<br/><br/>Given this information, which one of the following statements can be inferred with certainty?

    1. More than half of the pregnant women received medical care at least once from a doctor.
    2. Less than half of the pregnant women received medical care at least once from a doctor.
    3. More than half of the pregnant women received medical care at most once from a doctor.
    4. Less than half of the pregnant women received medical care at most once from a doctor.

    Answer: A

    Solution: Insight: 60% of the 90% who received care is 54% of the total, which is strictly more than half.
    Exam route: Calculate $0.60 \times 0.90 = 0.54$. Since $54\% > 50\%$, Option A is directly verified without needing to assume anything about overlap.
    Learning route: Let the total number of pregnant women be 100. The passage states 90 received care. Of these 90, 60% received care from doctors. 60% of 90 is 54. Thus, 54 out of 100 women (54%) received care from a doctor. Since 54% is strictly greater than 50%, it is certain that more than half received care from a doctor. The trap is to assume the 60% and 40% must overlap or be disjoint in a way that changes the total, but the question only asks about the doctor subset, which is firmly 54%.
    Wrong path: A student might add 60% and 40% to get 100% and assume they are disjoint, or try to find the overlap. This leads to confusion about the "at most once" opt

    GATE CS Preparation Resources 2026