ISC Class 12 Computer Science Board Exam Question Paper 2024 with Solutions

Download ISC Class 12 Computer Science Question Papers

Review targeted exam resources with the ISC Class 12 Computer Science Board Exam Question Paper 2024 with Solutions. Built according to official ISC standards for the 2026-27 academic year, these downloadable Class 12 Computer Science question papers support effective revision and performance tracking.

Access ISC Question Papers and Solutions

Access the complete question paper PDF for Class 12 Computer Science below. Regular practice with these targeted exam papers builds familiarity with standard question patterns and helps secure higher marks in final evaluations.

ISC Class 12 Computer Science Board Exam Question Paper with Solutions

 

PART I - 20 MARKS

 

1.1. According to the Principle of duality, the Boolean equation (A + B') • (A + 1) = A + B' will be equivalent to _____. [1 Mark]
1. (A' + B) • (A' + 1) = A' + B
2. (A • B') + (A • 0) = A • B'
3. (A' • B) + (A' • 1) = A' • B
4. (A' • B) + (A' • 0) = A' • B

Answer: (2) (A • B') + (A • 0) = A • B'

The principle of duality states that AND becomes OR, OR becomes AND, 0 becomes 1, and 1 becomes 0, while variables and complements remain unchanged.

Teacher's Note:
a) Replace each plus sign with a dot, each dot with a plus sign, 1 with 0, and 0 with 1 to obtain the dual.
b) Variables like A, B, and complements like B' do not change during the application of duality.

 

1.2. When a sequence of OR, NOT, NOR are connected in series, the logic gate obtained is _____. [1 Mark]
1. AND
2. NOT
3. OR
4. XOR

Answer: (3) OR

An OR gate output passed through a NOT gate gives NOR, and a NOR gate output passed through another NOT gate results in an OR gate.

Teacher's Note:
a) Combining logic gates sequentially requires tracking the logical output at each stage.
b) Double negation cancels out, returning the original logic operation.

 

1.3. Idempotence Law states that _____. [1 Mark]
1. X + X = X
2. X + X' = 0
3. X + X = 1
4. X + X' = X

Answer: (1) X + X = X

The Idempotence Law in Boolean algebra specifies that combining a variable with itself via AND or OR yields the variable itself (X • X = X and X + X = X).

Teacher's Note:
a) Memorize the standard Boolean algebra laws including Idempotent, Dominance, and Involution.
b) Do not confuse Idempotence with Complementarity laws (like X + X' = 1).

 

1.4. Assertion: For proposition ~A - B, its contrapositive is B - ~A
Reason: Contrapositive is the converse of inverse for any proposition. [1 Mark]

1. Both Assertion and Reason are true, and Reason is the correct explanation for the Assertion.
2. Both Assertion and Reason are true, but Reason is not the correct explanation for the Assertion.
3. Assertion is true but Reason is false.
4. Assertion is false but Reason is true.

Answer: (1) Both Assertion and Reason are true, and Reason is the correct explanation for the Assertion.

The inverse of A - B is ~A - ~B, and its converse is B - ~A, which forms the contrapositive.

Teacher's Note:
a) The contrapositive of conditional statements flips the terms and negates both.
b) Inverse negation followed by converse swapping gives the exact contrapositive definition.

 

1.5. The complement of the Boolean expression (P' • Q) (R • S') is _____. [1 Mark]
1. (P + Q) • (R' + S)
2. (P + Q') • (R' + S)
3. (P' + Q) • (R + S')
4. (P + Q') • (R + S')

Answer: (2) (P + Q') • (R' + S)

Applying De Morgan's Law to ((P'•Q) • (R•S'))' results in (P'•Q)' + (R•S')' = (P + Q') + (R' + S).

Teacher's Note:
a) De Morgan's law breaks products into sums and changes the signs of individual terms.
b) Double complement of a variable removes the complement apostrophe entirely.

 

1.6. Assertion: Recursive data structure follows the LIFO principle.
Reason: Execution of recursive code follows the concepts of data structure Queue. [1 Mark]

1. Both Assertion and Reason are true, and Reason is the correct explanation for the Assertion.
2. Both Assertion and Reason are true, but Reason is not the correct explanation for the Assertion.
3. Assertion is true but Reason is false.
4. Assertion is false but Reason is true.

Answer: (3) Assertion is true but Reason is false.

Recursion uses the system stack which operates on the Last In, First Out (LIFO) principle, whereas a Queue uses First In, First Out (FIFO).

Teacher's Note:
a) Stack frames are pushed and popped during recursive method calls.
b) Queues do not match recursive execution flows because they process items sequentially from the front.

 

1.7. State any one use of interfaces in Java. [1 Mark]

Answer:
Interfaces are used to achieve multiple inheritance in Java.

Teacher's Note:
a) Java classes can implement multiple interfaces simultaneously.
b) Interfaces provide fully abstract structures for defining common behavior across unrelated classes.

 

1.8. Write the cardinal form of the maxterm X + Y' + Z. [1 Mark]

Answer:
(010)2 = 2

Teacher's Note:
a) For maxterms, a non-complemented variable represents 0 and a complemented variable represents 1.
b) X + Y' + Z translates to binary 010, which evaluates to decimal 2.

 

1.9. Write the canonical SOP expression for F (A, B) = A <=> B. [1 Mark]

Answer:
F(A, B) = A • B + A' • B'

Teacher's Note:
a) The equivalence operator returns true when both inputs match (both 1 or both 0).
b) Canonical SOP sums up all minterms where the logical output equals 1.

 

1.10. State any one difference between instance variable and class variable. [1 Mark]

Answer:

Instance variableClass variable
Instance variables are created separately for every object instantiated from the class.Class variables are created once and shared across all instances of the class using the static keyword.

Teacher's Note:
a) Instance variables hold unique states per object.
b) Class variables use the static modifier and maintain a single shared memory location.

 

Q2.

2.1. Convert the following infix notation to postfix form.
(P + Q * R - S) / T * U [2 Marks]

Answer:
PQR*+S-T/U*

Teacher's Note:
a) Apply operator precedence rules where multiplication comes before addition and subtraction.
b) Operators with equal precedence are evaluated from left to right unless parentheses dictate otherwise.

 

2.2. An array ARR [ -5 ..... 15, 10 ..... 20] stores elements in Row Major Wise with each element requiring 2 bytes of storage. Find the address of ARR [10] [15] when the base address is 2500. [3 Marks]

Answer:
Address = 2840

Teacher's Note:
a) Use the row-major address calculation formula: Address = Base + W * ((I - Lr) * C + (J - Lc)).
b) Ensure correct calculation of total columns C = (Uc - Lc + 1) which is (20 - 10 + 1) = 11.

 

2.3. The following function is a part of some class:
int jolly(int[] x, int n, int m)
{
if (n<0)
return m;
else if(n<x.length)
m=(x[n]>m)?x[n]:m;
return jolly(x, --n, m);
}
a. What will be the output of jolly() when the value of x[]={6,3,4,7,1}, n=4 and m=0?
b. What function does jolly() perform, apart from recursion? [3 Marks]

Answer:
a. 7
b. Finding and returning the maximum element present in the integer array x[].

Teacher's Note:
a) Trace recursive calls step by step, updating the maximum value variable m on each iteration.
b) Note the pre-decrement operator --n inside the recursive call argument list.

 

2.4. The following function is a part of some class which is used to find the smallest digit present in a number. There are some places in the code marked by ?1?, ?2?, ?3? which must be replaced by an expression/a statement so that the function works correctly.
int small_dig(int n)
{ int min=?1?;
while(n!=0)
{
int q=n/10;
int r=?2?*10;
min=r>min? ?3? : r;
n=q;
}
return min;
}
a. What is the expression or statement at ?1?
b. What is the expression or statement at ?2?
c. What is the expression or statement at ?3? [3 Marks]

Answer:
a. n
b. n%10+0
c. min

Teacher's Note:
a) Initializing min to n or 9 ensures proper comparison with extracted individual digits.
b) Modulus operator % extracts the rightmost digit for comparison.

 

PART II - 50 MARKS

SECTION - A (Answer any two questions.)

 

Q3.

3.1. To be recruited as the Principal in a renowned College, a candidate must satisfy any one of the following criteria:
- The candidate must be a Postgraduate and should either possess a B.Ed. degree or a teaching experience of more than 15 years.
OR
- The candidate must be an employee of the same college with a teaching experience of more than 15 years.
OR
- The candidate must be a Postgraduate but not an employee of the same college and should have a teaching experience of more than 15 years.
The inputs are:
[Table with inputs P, S, E, B]
Draw the truth table for the inputs and outputs given above and write the SOP expression for X (P, S, E, B). [5 Marks]

Answer:
X(P, S, E, B) = P' • S • E • B' + P' • S • E • B + P • S' • E' • B + P • S' • E' • B' + P • S' • E • B + P • S' • E • B' + P • S • E • B' + P • S • E • B
= Summation(6, 7, 9, 10, 11, 13, 14, 15)

Teacher's Note:
a) Carefully interpret each recruitment criterion into boolean conditional terms.
b) Construct the complete 16-row truth table to capture all valid minterm combinations.

 

3.2. Reduce the above expression X (P, S, E, B) by using 4-variable Karnaugh map, showing the various groups (i.e., octal, quads and pairs).
Draw the logic gate diagram for the reduced expression. Assume that the variables and their complements are available as inputs. [5 Marks]

Answer:
X(P, S, E, B) = S • E + P • B + P • E

Teacher's Note:
a) Group adjacent 1s into maximal quads and octals to achieve minimal SOP form.
b) Draw clear logic gate connections matching the minimized boolean expression.

 

Q4.

4.1. (a) Reduce the Boolean function F (A, B, C, D) = Pi (0, 2, 4, 6, 8, 9, 10, 11, 14) by using 4-variable Karnaugh map, showing the various groups (i.e., octal, quads and pairs). [4 Marks]

Answer:
F(A, B, C, D) = (A + D) • (C' + D) • (A' + B)

Teacher's Note:
a) Pi notation represents maxterms, requiring zeroes to be placed on the K-map.
b) Group adjacent 0s to form POS (Product of Sums) expressions.

 

4.1. (b) Draw the logic gate diagram for the reduced expression. Assume that the variables and their complements are available as inputs. [2 Marks]

Answer:
[Figure: Logic circuit diagram featuring OR gates for (A + D), (C' + D), (A' + B) connected to a final AND gate.]

Teacher's Note:
a) Use OR gates for individual sums and feed their outputs into a central AND gate.
b) Ensure all required variable complements are routed properly.

 

4.2. Verify if the following proposition is a Tautology, Contradiction or Contingency using a truth table.
((A => B) ^ (B => C)) => (A => C) [4 Marks]

Answer:
It is a Tautology.

Teacher's Note:
a) A proposition whose truth table column evaluates entirely to true (1) is a Tautology.
b) This represents the hypothetical syllogism rule in propositional logic.

 

4.3. Find the complement of the following expression and reduce it by using Boolean laws.
P • ( (13 + Q) • Q • (Q + R') ) [5 Marks]

Answer:
P' + Q'

Teacher's Note:
a) Apply De Morgan's law systematically to break down compound negated terms.
b) Use absorption and idempotency laws to simplify the final boolean expression.

 

Q5.

5.1. (a) How is a decoder different from a multiplexer? [2 Marks]

Answer:

MultiplexerDecoder
Contains several data input lines and one single output line.Contains no data input lines and several output lines.

Teacher's Note:
a) Multiplexers select one input out of many to route to a single output.
b) Decoders convert binary address inputs into unique active output lines.

 

5.1. (b) Draw the logic circuit for 3:8 decoder (Octal decoder). Which multiplexer can be derived from the Octal decoder? [3 Marks]

Answer:
[Figure: Logic diagram of 3-to-8 decoder with 3 input lines B2, B1, B0 and 8 AND gate outputs Oc0 to Oc7]
An 8:1 Multiplexer can be derived.

Teacher's Note:
a) A 3-to-8 decoder takes 3 select inputs and generates 23 = 8 minterm outputs.
b) Connecting these minterms with data inputs yields an 8:1 multiplexer circuit.

 

5.2. Draw the logic gate diagram for 2-input OR gate using NAND gates only. Show the expression at each Step. [3 Marks]

Answer:
[Figure: Two NAND gates connected in NOT configuration feeding into a final NAND gate to produce A + B.]

Teacher's Note:
a) NAND is a universal gate capable of implementing any boolean function.
b) Use De Morgan's law to convert an OR expression into equivalent NAND forms: A + B = ((A')' + (B')')' = (A' • B')'.

 

5.3. Write the canonical form of the cardinal terms, m3 and m5 for F (A, B, C, D). [2 Marks]

Answer:
m3 = A' • B' • C • D (in minterm) or A + B + C' + D' (in maxterm)
m5 = A' • B • C' • D (in minterm) or A + B' + C + D' (in maxterm)

Teacher's Note:
a) Convert decimal indices 3 and 5 into 4-bit binary equivalents (0011 and 0101).
b) Represent 0 as a complemented variable and 1 as uncomplemented for minterms.

 

SECTION - B (Answer any two questions.)

 

Q6. Design a class DeciHex to accept a positive integer in decimal number system from the user and display its hexadecimal equivalent. [15 Marks]

Answer:

import java.util.Scanner;
class DeciHex
{
    int num;
    String hexa;

    public DeciHex()
    {
        num=0;
        hexa="";
    }

    public void getNum()
    {
        Scanner sc=new Scanner(System.in);
        System.out.println("Enter the decimal no. Positive number only");
        num=Math.abs(sc.nextInt());
    }

    public void convert(int n)
    {
        if(n==0)
            return;
        else
        {
            int a=n%16;
            if(a>=0&&a<=9)
                hexa=""+a+hexa;
            else
            {
                switch(a)
                {
                    case 10: hexa='A'+hexa; break;
                    case 11: hexa='B'+hexa; break;
                    case 12: hexa='C'+hexa; break;
                    case 13: hexa='D'+hexa; break;
                    case 14: hexa='E'+hexa; break;
                    case 15: hexa='F'+hexa; break;
                }
            }
            convert(n/16);
        }
    }

    public void display()
    {
        convert(num);
        System.out.println("Decimal No. "+num);
        System.out.println("Hexa Decimal equivalent."+hexa);
    }

    public static void main(String ar[])
    {
        DeciHex ob=new DeciHex();
        ob.getNum();
        ob.display();
    }
}

Teacher's Note:
a) Use recursive division by 16 to extract hexadecimal remainders.
b) Handle values from 10 to 15 using character mappings ('A' through 'F').

 

Q7. A class InsSort contains an array of integers which sorts the elements in a particular order. [15 Marks]

Answer:

import java.util.Scanner;
class InsSort
{
    int arr[];
    int size;

    public InsSort(int s)
    {
        size=Math.abs(s);
        arr=new int[size];
    }

    public void getArray()
    {
        Scanner sc=new Scanner(System.in);
        System.out.println("Enter "+size+" number for the array");
        for(int i=0;i<size;i++)
            arr[i]=sc.nextInt();
    }

    public void insertionSort()
    {
        for(int i=1;i<size;i++)
        {
            int b=arr[i];
            int j=i-1;
            while(j>=0&&arr[j]<b)
            {
                arr[j+1]=arr[j];
                j--;
            }
            arr[j+1]=b;
        }
    }

    public double find()
    {
        int odd=0,c=0;
        for(int i=0;i<size;i++)
        {
            if(arr[i]%2!=0)
            {
                odd+=arr[i];
                c++;
            }
        }
        return (double)odd/c;
    }

    public void display()
    {
        insertionSort();
        System.out.println("Array elements after sorting");
        for(int i=0;i<size;i++)
            System.out.print(arr[i]+" ");
        System.out.println("\nAverage of odd numbers:"+find());
    }

    public static void main(String args[])
    {
        Scanner ins=new Scanner(System.in);
        System.out.println("Enter the size of the array");
        int a=ins.nextInt();
        InsSort obi=new InsSort(a);
        obi.getArray();
        obi.display();
    }
}

Teacher's Note:
a) Implement descending order insertion sort by comparing elements and shifting right.
b) Compute the average of odd elements by checking modulus condition (!= 0).

 

Q8. Design a class Coding to perform some string related operations on a word containing alphabets only. [15 Marks]

Answer:

import java.util.*;
class Coding
{
    String wrd;
    int len;

    public Coding()
    {
        wrd="";
        len=0;
    }

    public void accept()
    {
        Scanner sc=new Scanner(System.in);
        System.out.println("Enter a word");
        wrd=sc.next().trim();
    }

    public void find()
    {
        len=wrd.length();
        int small=122,large=65;
        for(int i=0;i<len;i++)
        {
            char ch=wrd.charAt(i);
            if((int)ch>large)
                large=ch;
            else if((int)ch<small)
                small=ch;
            System.out.println(ch+"="+(int)ch);
        }
        System.out.println("Lowest ASCII code:"+small);
        System.out.println("Highest ASCII code:"+large);
    }

    public void show()
    {
        System.out.println("Original word: "+wrd);
        find();
    }

    public static void main(String ar[])
    {
        Coding ob=new Coding();
        ob.accept();
        ob.show();
    }
}

Teacher's Note:
a) Extract individual characters using charAt() and cast them to integers to obtain ASCII values.
b) Maintain running minimum and maximum variables initialized appropriately.

 

SECTION - C (Answer any two questions.)

 

Q9. CardGame is a game of mental skill, built on the simple premise of adding and removing the cards from the top of the card pile.
i. Specify the class CardGame giving details of the functions void addCard(int v) and int drawCard().
ii. Name the entity described above and state its principle. [10 Marks]

Answer:
(i)

class CardGame
{
    int cards[];
    int cap,top;

    public CardGame(int cc)
    {
        cap=Math.abs(cc);
        top=-1;
        cards=new int[cap];
    }

    public void addCard(int v)
    {
        top++;
        if(top==cap)
        {
            System.out.println("CARD PILE IS FULL");
            top--;
        }
        else
        {
            cards[top]=v;
        }
    }

    public int drawCard()
    {
        if(top==-1)
        {
            System.out.println("CARD PILE IS EMPTY");
            return -9999;
        }
        else
        {
            return cards[top--];
        }
    }

    public void display()
    {
        if(top==-1)
            System.out.println("EMPTY CARD PILE");
        else
        {
            for(int i=top;i>=0;i--)
                System.out.println(cards[i]);
        }
    }
}

(ii) The above entity is a Stack and its principle is Last In First Out (LIFO).

Teacher's Note:
a) Stack push and pop operations manipulate the top index pointer.
b) Check for overflow and underflow conditions before inserting or deleting elements.

 

Q10. A super class EmpSal has been defined to store the details of an employee. Define a subclass Overtime to compute the total salary of the employee, after adding the overtime amount based on the criteria. [10 Marks]

Answer:

class Overtime extends EmpSal
{
    int hours;
    double totsal;

    public Overtime(String n, int e, double s, int h)
    {
        super(n,e,s);
        hours=h;
    }

    public void calSal()
    {
        if(hours>40)
            totsal = salary+5000;
        else if(hours>=30)
            totsal = salary+3000;
        else
            totsal = salary;
    }

    public void show()
    {
        super.show();
        System.out.println("Total salary:"+totsal);
    }
}

Teacher's Note:
a) Use the super keyword to invoke the parameterized constructor of the parent class.
b) Implement conditional branch checks accurately according to the specified overtime hour slabs.

 

Q11.

11.1. With the help of an example, briefly explain the dominant term in complexity. [2 Marks]

Answer:
When determining algorithm performance, the dominant term is the component that grows fastest as input size increases, such as N2 in an algorithm with nested loops running N2 times and a single loop running N times, giving overall complexity O(N2).

Teacher's Note:
a) Lower-order terms and constant multipliers are dropped when expressing Big-O complexity.
b) The term with the highest growth rate dictates the scalability limits.

 

11.2. Answer the following questions based on the diagram of a Binary Tree given below:
[Figure: Binary tree rooted at A, with left child E (having left child M with children F and I) and right child H (having left child L with child C, and right child G)]
a. Name the external nodes of the tree.
b. State the degree of node M and node L.
c. Write the post-order traversal of the above tree structure. [3 Marks]

Answer:
a. F, I, C, G
b. Degree of M is 2, Degree of L is 1
c. F, I, M, E, C, L, G, H, A

Teacher's Note:
a) External nodes (leaves) have no children.
b) Post-order traversal follows Left, Right, Root recursive ordering.

Free study material for Computer Science

Download ISC Question Papers: Class 12 Computer Science

Class 12 Computer Science Past Exam Papers & Resources

Access structured past examination sets for Class 12 Computer Science. Solving the ISC Class 12 Computer Science Board Exam Question Paper 2024 with Solutions provided above helps students understand actual exam difficulty levels, question formats, and topic distributions for both descriptive and objective sections.

Importance of Solving ISC Class 12 Computer Science Board Exam Question Paper 2024 with Solutions

Practicing past question sets under timed home conditions helps refine pacing and time management skills, ensuring you complete your Computer Science examination comfortably within the official duration.

Complete Your Exam Preparation

Download digital copies of these papers for convenient offline revision anywhere. Cross-check your completed steps against our expert solution guides to ensure complete accuracy.

FAQs

Where can I download the official PDF for ISC Class 12 Computer Science Board Exam Question Paper 2024 with Solutions?

The ISC Class 12 Computer Science Board Exam Question Paper 2024 with Solutions is available for download on StudiesToday.com. It includes complete set with all sections so that Class 12 students can practice with the exact same paper that came in the ISC exams.

Are the solutions for ISC Class 12 Computer Science Board Exam Question Paper 2024 with Solutions based on the official ISC marking scheme?

Yes, the solutions for ISC Class 12 Computer Science Board Exam Question Paper 2024 with Solutions are prepared by subject matter experts as per official marking scheme. Class 12 students will understand the structure of answers and 'step-marks' methodology Computer Science.

How does solving ISC Class 12 Computer Science Board Exam Question Paper 2024 with Solutions help in preparing for the 2026 exams?

Solving previous year papers like ISC Class 12 Computer Science Board Exam Question Paper 2024 with Solutions is important to understand repeat themes and question difficulty levels of Computer Science. It helps Class 12 students to test their time management skills too.

Can I access ISC Class 12 Computer Science Board Exam Question Paper 2024 with Solutions in different languages?

Yes, where applicable, ISC Class 12 Computer Science Board Exam Question Paper 2024 with Solutions is available in both English and Hindi mediums. All students from Class 12 can access Computer Science study material in their preferred language.

Is there a charge to download the ISC Class 12 Computer Science solved papers?

No, all previous year question papers on StudiesToday, including ISC Class 12 Computer Science Board Exam Question Paper 2024 with Solutions, are provided free of charge in mobile-friendly PDF.