In short: Nobody outside CBSE knows the exact 2027 Computer Science questions, so this list ranks question types by evidence: the unit marks (Python 40, Database 20, Networks 10), the section layout reported for the 37-question paper, and what teachers said about the March 25, 2026 paper. Programs are the most predictable part, so every code example below was run in Python 3.11 and every SQL query was run on SQLite, and the printed outputs are real. Treat this as a practice priority list, not a leak.
Last updated: October 28, 2026. The 2027 date sheet is not out yet. The section layout below is the one reported for the 37-question paper, and I could not open the 2026-27 sample paper itself.
CBSE Class 12 Computer Science 2027 — Quick Reference
| Parameter | Details |
|---|---|
| Subject code | 083 |
| Theory paper | 70 marks, 3 hours |
| Practical | 30 marks |
| Unit I: Computational Thinking and Programming | 40 marks |
| Unit II: Computer Networks | 10 marks |
| Unit III: Database Management | 20 marks |
| Questions in the 2026 paper | 37, in five sections A to E |
| 2026 paper date | Wednesday, March 25, 2026 |
| Language for programs | Python only |
Sources: EdexLive and Kollege Apply for the unit marks. Times Now for the date and section notes. MSN for the 37 questions. The units add up: 40 + 10 + 20 = 70.
Section layout
A pre-board paper for 2025-26 that follows the CBSE pattern shows this split, and it matches Times Now's section notes below:
| Section | Questions | Marks each | Total |
|---|---|---|---|
| A | 21 (MCQs, output tracing, assertion-reason) | 1 | 21 |
| B | 7 | 2 | 14 |
| C | 3 | 3 | 9 |
| D | 4 | 4 | 16 |
| E | 2 | 5 | 10 |
| Total | 37 | 70 |
The split adds up to 37 questions and 70 marks. I took the counts from a school pre-board paper, not the official sample paper, so confirm them on the CBSE academic site.
What I could not verify
| Item | Status |
|---|---|
| The 2026-27 official sample paper layout | Not opened. Confirm the section counts above |
| Marks for each topic inside Unit I | Not confirmed. EdexLive gives only the three unit totals |
| Python-MySQL code | The connector snippet below was not run, since it needs a MySQL server |
What the 2026 Paper Showed
| Observation | Source |
|---|---|
| Easy to moderate overall. Section A easy, B and C basic understanding, D easy, E (case study) needed logical thinking | Times Now |
| Output-based and error-based programming questions were simple and manageable. Theory was direct | Times Now (Silverline Prestige School teacher) |
| Section A mixed MCQs, output tracing and assertion-reason questions | Times Now |
| Section B mixed debugging, output prediction, SQL commands and definitions, with balanced internal choices | Times Now |
| Section C covered file handling, stack operations and code tracing | Times Now |
| Section D used real-world scenarios for SQL, CSV handling and Python-MySQL connectivity | Times Now |
| Section E had long answers on binary file handling and networking | Times Now |
| Python questions were mostly direct but needed logic building and output tracing in places. SQL queries were simple and predictable | Times Now (Noida teacher) |
Before the exam, a Ghaziabad teacher quoted by Times Now advised attempting Python questions first and writing neat, properly indented code. He listed SELECT, WHERE, aggregate functions and GROUP BY as the SQL basics, and a four-block office network case study as common.
Unit I: Python Programs (40 Marks)
Stack
| # | Expected question | Evidence |
|---|---|---|
| 1 | Write functions to push, pop and display a stack implemented as a list | 2026 paper (stack operations in Section C) |
stack = []
def push(item):
stack.append(item)
def pop():
if not stack:
return "Underflow"
return stack.pop()
def display():
for i in range(len(stack) - 1, -1, -1):
print(stack[i], end=" ")
print()
push(10); push(20); push(30)
display() # 30 20 10
print(pop()) # 30
display() # 20 10
Run output: 30 20 10, then 30, then 20 10. After clearing the stack, pop() returns Underflow. A stack follows last in, first out, so display from the top.
Text file handling
| # | Expected question | Evidence |
|---|---|---|
| 2 | Count lines starting with a given letter | 2026 paper (file handling in Section C) |
| 3 | Count vowels and words in a text file | 2026 paper |
count = 0
with open("story.txt", "r") as f:
for line in f:
if line[0] in "Aa":
count += 1
print("Lines starting with A:", count)
with open("story.txt") as f:
data = f.read()
vowels = sum(1 for ch in data if ch.lower() in "aeiou")
words = len(data.split())
print(vowels, words)
Test file used: "Apple is red", "Banana is yellow", "Ant is small", "Grapes are green" (four lines). Run output: 2 lines start with A, 19 vowels, 12 words.
Binary file handling (Section E topic in 2026)
| # | Expected question | Evidence |
|---|---|---|
| 4 | Search a binary file for records that match a condition | 2026 paper (binary file handling in Section E) |
| 5 | Update a record in a binary file | 2026 paper |
import pickle
def search_by_salary(limit):
found = 0
with open("emp.dat", "rb") as f:
try:
while True:
rec = pickle.load(f)
if rec[2] > limit:
print(rec)
found += 1
except EOFError:
pass
return found
Records stored as lists [id, name, salary]: [101, 'Asha', 52000], [102, 'Ravi', 41000], [103, 'Meena', 60000]. With a limit of 50000, the run printed [101, 'Asha', 52000] and [103, 'Meena', 60000] and returned 2.
For an update, read every record into a list, change the matching one, then rewrite the file in wb mode:
def raise_salary(eid, amt):
recs = []
with open("emp.dat", "rb") as f:
try:
while True:
recs.append(pickle.load(f))
except EOFError:
pass
for r in recs:
if r[0] == eid:
r[2] += amt
with open("emp.dat", "wb") as f:
for r in recs:
pickle.dump(r, f)
Run output after raise_salary(102, 5000): record 102 shows 46000. Always say the file is opened with rb, wb or ab and that pickle is imported.
CSV handling (Section D topic in 2026)
| # | Expected question | Evidence |
|---|---|---|
| 6 | Write rows to a CSV file and read them back with a condition | 2026 paper (CSV handling in Section D) |
import csv
with open("marks.csv", "w", newline="") as f:
w = csv.writer(f)
w.writerow(["Roll", "Name", "Marks"])
w.writerow([1, "Isha", 78])
w.writerow([2, "Kabir", 91])
w.writerow([3, "Tara", 84])
with open("marks.csv", "r", newline="") as f:
r = csv.reader(f)
next(r) # skip the header
total = above = 0
for row in r:
total += 1
if int(row[2]) > 80:
above += 1
print(total, above) # 3 2
Run output: 3 rows and 2 with marks above 80. Do not forget newline="" and the next(r) call that skips the header.
Output tracing and functions
| # | Expected question | Evidence |
|---|---|---|
| 7 | Output of a function with default arguments | 2026 paper (output tracing, Section A and C) |
| 8 | Output of a function that changes a list argument | 2026 paper |
| 9 | Output of string slicing, list sorting and dictionary updates | 2026 paper |
def calc(a, b=5, c=2):
a = a + b
b = b * c
return a, b
print(calc(3)) # (8, 10)
print(calc(3, 4, 1)) # (7, 4)
def change(lst):
lst.append(99) # changes the caller's list
lst = [1, 2] # rebinds the local name only
return lst
L = [5, 6]
print(change(L), L) # [1, 2] [5, 6, 99]
s = "COMPUTER"
print(s[1:5], s[::-1], s[-3:]) # OMPU RETUPMOC TER
t = [3, 8, 1, 9]
t.sort(reverse=True)
print(t, t[1:3]) # [9, 8, 3, 1] [8, 3]
d = {"a": 1, "b": 2}
d["c"] = d.get("c", 0) + 7
print(d) # {'a': 1, 'b': 2, 'c': 7}
The outputs shown are the real run outputs. The change example is a favourite: appending changes the list the caller passed in, but assigning a new list to the parameter does not.
Debugging questions
| # | Expected question | Evidence |
|---|---|---|
| 10 | Find and correct errors in a short code fragment | 2026 paper (debugging in Section B) |
Look for four classic slips: a missing colon, wrong indentation, = used where == is needed, and a wrong mode string when opening a file.
Practice CBSE Science on Padhaao
AI tutor with 10 learning modes · Quiz, Flashcards, Exam Practice & more · 3 free chapters daily
Unit III: Database Management (20 Marks)
SQL queries
All queries below ran on SQLite, and the syntax is the same in MySQL. The table was student(roll, name, class, marks) with rows Isha A 78, Kabir A 91, Tara B 84, Dev B 66, Mira B 72, Zoya C 95.
| # | Expected question | Evidence |
|---|---|---|
| 11 | Group, aggregate and filter groups | Teachers named GROUP BY and aggregates (Times Now). SQL queries were predictable (2026) |
| 12 | Filter with BETWEEN and sort | Syllabus |
| 13 | MAX, MIN and other aggregates | Aggregates named by a Ghaziabad teacher |
| 14 | Join two tables | Joins are in the syllabus |
SELECT class, COUNT(*), AVG(marks) FROM student GROUP BY class;
-- A 2 84.5 | B 3 74.0 | C 1 95.0
SELECT class, AVG(marks) FROM student GROUP BY class HAVING COUNT(*) >= 2;
-- A 84.5 | B 74.0
SELECT name FROM student WHERE marks BETWEEN 70 AND 90 ORDER BY marks DESC;
-- Tara, Isha, Mira
SELECT MAX(marks), MIN(marks) FROM student;
-- 95 | 66
SELECT ename, dname FROM emp, dept WHERE emp.did = dept.did;
-- Anu Sales | Bhav IT | Chet IT
SELECT dname, COUNT(*) FROM emp NATURAL JOIN dept GROUP BY dname;
-- IT 2 | Sales 1
Write the clauses in order: SELECT, FROM, WHERE, GROUP BY, HAVING, ORDER BY. WHERE filters rows and HAVING filters groups.
Python and MySQL connectivity
| # | Expected question | Evidence |
|---|---|---|
| 15 | Connect Python to MySQL, run a query and print the rows | 2026 paper (Python-MySQL connectivity in Section D) |
import mysql.connector as sql
con = sql.connect(host="localhost", user="root", passwd="yourpassword", database="school")
cur = con.cursor()
cur.execute("SELECT * FROM student WHERE marks > 80")
for row in cur.fetchall():
print(row)
con.close()
I did not run this one because it needs a MySQL server. Use the steps in order: import, connect, create a cursor, execute, fetch, then close. Replace the password with your own, and never put a real password in shared code.
Unit II: Computer Networks (10 Marks)
| # | Expected question | Evidence |
|---|---|---|
| 16 | A four-block office case study: place the server, choose the network type, and place hubs, switches or repeaters | 2026 paper (networking in Section E). Called common by a Ghaziabad teacher |
| 17 | Types of networks (LAN, MAN, WAN) and their differences | Teacher-listed |
| 18 | Network devices, protocols and topologies such as star and bus | Teacher-listed |
Answer format
| Part of the case study | What to write |
|---|---|
| Server placement | Put the server in the block with the most computers, and say so, because it reduces traffic |
| Network type | Choose LAN for one campus, MAN for a city, WAN for cities or countries |
| Repeater | Needed where the cable between two blocks is longer than the usual limit. Mark the distance the question gives |
| Hub or switch | Place one in each block. A switch is preferred, since it sends data only to the intended device |
| Topology | Star is easy to manage and one failed cable does not stop the rest. Bus is cheap but a break affects the network |
Section-Wise Tips
| Section | Tip |
|---|---|
| A (21 x 1) | Trace output on paper line by line. For assertion-reason, check each statement separately |
| B (7 x 2) | Use the internal choice. Show the corrected line for a debugging question |
| C (3 x 3) | Write the full function with the right file mode. Do not skip the with block's indentation |
| D (4 x 4) | Read the scenario once and write the query clause by clause |
| E (2 x 5) | Handle EOFError in binary-file loops. Draw the network layout in the case study |
4-Week Practice Plan
| Week | Focus | Questions in this list |
|---|---|---|
| Week 1 | Functions, output tracing, strings and lists | 7 to 10 |
| Week 2 | Stack, text, binary and CSV files | 1 to 6. Write each program by hand |
| Week 3 | SQL and Python-MySQL | 11 to 15. Write twenty queries on one table |
| Week 4 | Networks and full papers | 16 to 18, then two full timed papers |
This is a suggestion, not an official schedule. Our sample paper guide shows how to review a paper after solving it.
Frequently Asked Questions
Are these the exact questions in the 2027 Computer Science board exam?
No. Nobody outside CBSE knows the 2027 questions. This list ranks question types by evidence from the unit marks, the section layout and what teachers reported about the 2026 paper. Any page or channel that promises the actual paper is a scam.
How many marks does each unit carry?
Computational Thinking and Programming carries 40 marks, Database Management 20 and Computer Networks 10, making 70 for theory. Practical work carries 30.
What topics did the 2026 paper cover?
Teachers quoted by Times Now described output tracing, debugging and SQL commands in the short sections, file handling and stack operations in Section C, SQL scenarios with CSV handling and Python-MySQL connectivity in Section D, and binary file handling plus networking in Section E.
Was the 2026 Computer Science paper difficult?
Easy to moderate. Section A and D were easy, B and C needed basic understanding, and the Section E case study needed logical thinking. A Noida teacher said Python questions were mostly direct but needed logic building in places, and SQL queries were predictable.
Do I have to write programs in Python only?
Yes. The paper instructions in the pre-board paper I checked say all programming questions are to be answered using Python. Write neat, properly indented code. A Ghaziabad teacher quoted by Times Now advised careful attention to indentation and syntax to avoid common errors.
How do I prepare for the network case study?
Practise the four-block office layout: put the server in the largest block, name the network type, and place hubs, switches and repeaters with a reason. Draw the layout. A teacher quoted by Times Now called this scenario common.
Related Guides
- CBSE Class 12 Maths — 25 Most Expected Questions Board 2027
- CBSE Class 12 Physics — 25 Most Expected Questions 2027
- CBSE Class 12 Science Last 100 Days Plan 2027
- How to Use CBSE Sample Papers 2027 Effectively
- How to Write Answers in Board Exams: Subject-Wise Examples
- B.Tech vs BCA vs B.Sc CS: Degree Comparison
Sources
- EdexLive: CBSE Class 12 Computer Science weightage 2027
- Times Now: Class 12 Computer Science paper analysis 2026
- Times Now: last-minute tips for Class 12 Computer Science
- MSN: CBSE Class 12 Computer Science question paper 2026
- Kollege Apply: Class 12 Computer Science syllabus
₹21/mo (annual plan)
Padhaao covers every CBSE Science chapter
1,005 chapters across all subjects. 2.5 crore+ students. Pro from ₹21/month (annual plan).
Practice CBSE Science chapters with AI
Every chapter from your syllabus. 10 learning modes. 3 free every day.
Start Science