MCA-102 Data and File Structures Notes from Unnati Educations are a 90-page printed book for GGSIPU MCA Semester 2. They cover all 4 official units with 68 C code listings (24 with actual run output), 16 solved examples, 32 figures and 88 exam-style practice questions, and follow the MCA scheme in force from academic session 2025-26.
Written by Prateek Talwar, Founder, Unnati Educations · Reviewed by Ritik Rawat, B.Tech, Senior Full Stack Developer · Checked against the MCA Scheme of Examination & Detailed Syllabus, 01 Aug 2025 · Updated 13 October 2026 · Editorial policy
Scheme: MCA (02 Years), affiliated institutes, A.S. 2025-26 onwards | Applies to: batch admitted 2025-26 onwards | Verified against: MCA Scheme of Examination & Detailed Syllabus, 01 Aug 2025
MCA-102 Data and File Structures at a glance: GGSIPU MCA Sem 2 credits, units and exam pattern
MCA-102 is a compulsory Semester 2 theory paper beside MCA-104 and MCA-106; its prerequisites are Discrete Structures and programming skills.
| Code and title | MCA-102 Data and File Structures |
|---|---|
| Course and semester | MCA (2 years), Semester 2 |
| Type and credits | Compulsory theory; L 3, T/P nil, 3 credits; 45 hours |
| Marks | Pass mark 40 out of 100; end-term 60; internal split not printed |
| Applies to | Affiliated institutes, session 2025-26 onwards |
| End-term pattern | Q1 compulsory short answers on the whole syllabus, 12 marks; one of two questions per unit, 12 marks each (12 + 48 = 60 marks) |
| Units | 4 |
| Paired lab | MCA-162 Data and File Structures Lab, L 0, P 2, 1 credit |
Other papers of this term are on the GGSIPU MCA Semester 2 papers page.
MCA-102 Data and File Structures Notes unit-wise: 68 C listings and 16 solved examples across 4 units
These GGSIPU MCA Sem 2 Data and File Structures notes run to 90 pages; each unit ends with a revision sheet, a Common Mistakes table and an Exam Corner. Notes for other papers sit under GGSIPU MCA notes.
MCA-102 Unit 1: Introduction to Linear Data Structures
Pages 4 to 30, sections 1.1 to 1.9. Array address formulas with negative bounds, sparse matrix triplets, both searches and six sorts traced on one input; then four kinds of linked list, polynomial addition, stacks, Polish notation, circular queues, quick sort and recursion.
Count: 22 C listings (6 with run output), 7 solved examples, 6 figures.
| Sort | Best | Worst | Stable? |
|---|---|---|---|
| Insertion | O(n) | O(n²) | Yes |
| Merge | O(n log n) | O(n log n) | Yes |
| Quick | O(n log n) | O(n²) | No |
| Radix | O(d(n+k)) | O(d(n+k)) | Yes |
Quick look: sorting complexity and stability (from page 15)
- Sort
- Insertion
- Best
- O(n)
- Worst
- O(n²)
- Stable?
- Yes
- Sort
- Merge
- Best
- O(n log n)
- Worst
- O(n log n)
- Stable?
- Yes
- Sort
- Quick
- Best
- O(n log n)
- Worst
- O(n²)
- Stable?
- No
- Sort
- Radix
- Best
- O(d(n+k))
- Worst
- O(d(n+k))
- Stable?
- Yes
MCA-102 Unit 2: Non Linear Data Structures: Trees
Pages 31 to 53, sections 2.1 to 2.9. BST operations with the three delete cases, recursive and stack-based traversals, threaded trees, tries, AVL insertion and deletion in C, an order-5 B-tree build, B+ and B* trees, heap sort and a heap-based priority queue.
Count: 22 C listings (6 with run output), 5 solved examples, 12 figures.
| Case | New node in | Fix |
|---|---|---|
| LL | Left subtree of left child | Single right rotation |
| RR | Right subtree of right child | Single left rotation |
| LR | Right subtree of left child | Left on child, then right |
| RL | Left subtree of right child | Right on child, then left |
Quick look: the four AVL rotation cases (from page 42)
- Case
- LL
- New node in
- Left subtree of left child
- Fix
- Single right rotation
- Case
- RR
- New node in
- Right subtree of right child
- Fix
- Single left rotation
- Case
- LR
- New node in
- Right subtree of left child
- Fix
- Left on child, then right
- Case
- RL
- New node in
- Left subtree of right child
- Fix
- Right on child, then left
MCA-102 Unit 3: Non-Linear Data Structures: Graphs
Pages 54 to 73, sections 3.1 to 3.7. Both representations in C, BFS and DFS traces, connected components, and one 6-vertex graph reused for Kruskal, Prim (both MST cost 13) and Dijkstra. Floyd-Warshall, two topological sorts and three case studies close the unit.
Count: 12 C listings (7 with run output), 1 solved example, 10 figures.
Quick look: Floyd-Warshall core loop (from page 67)
for (int k = 0; k < N; k++) /* k must be the outer loop */
for (int i = 0; i < N; i++)
for (int j = 0; j < N; j++)
if (d[i][k] + d[k][j] < d[i][j])
d[i][j] = d[i][k] + d[k][j];Final row 1 on the notes' graph: 0 3 5 6.
MCA-102 Unit 4: Hashing and File Structures
Pages 74 to 90, sections 4.1 to 4.7. Six hash functions, chaining, three probing methods and rehashing; then sequential files in C, binary files with fseek, and external sorting up to a 21-run polyphase merge.
Count: 12 C listings (5 with run output), 3 solved examples, 4 figures.
| Function | What it does |
|---|---|
fseek(fp, offset, origin) | Moves the position from SEEK_SET, SEEK_CUR or SEEK_END |
ftell(fp) | Current position in bytes from the start |
rewind(fp) | Back to the start |
fread(ptr, size, n, fp) | Reads n fixed-size records; 0 at end of file |
Quick look: random access in binary files (from page 83)
- Function
fseek(fp, offset, origin)- What it does
- Moves the position from SEEK_SET, SEEK_CUR or SEEK_END
- Function
ftell(fp)- What it does
- Current position in bytes from the start
- Function
rewind(fp)- What it does
- Back to the start
- Function
fread(ptr, size, n, fp)- What it does
- Reads n fixed-size records; 0 at end of file
MCA-102 exam corner: 48 short-answer and 40 long-answer practice questions by unit
Each unit ends with 12 short-answer and 10 long-answer exam-style practice questions, without past-year tags.
| Unit | Short | Long | Solved examples |
|---|---|---|---|
| 1 Linear structures | 12 | 10 | 7 |
| 2 Trees | 12 | 10 | 5 |
| 3 Graphs | 12 | 10 | 1 |
| 4 Hashing and files | 12 | 10 | 3 |
MCA-102 practice questions per unit
- Unit
- 1 Linear structures
- Short
- 12
- Long
- 10
- Solved examples
- 7
- Unit
- 2 Trees
- Short
- 12
- Long
- 10
- Solved examples
- 5
- Unit
- 3 Graphs
- Short
- 12
- Long
- 10
- Solved examples
- 1
- Unit
- 4 Hashing and files
- Short
- 12
- Long
- 10
- Solved examples
- 3
The MCA-102 notes give 48 short-answer and 40 long-answer practice questions across 4 units, plus 16 solved examples and 68 C listings, 24 with run output.
- Unit 1: Convert
A * (B + C) / D − Eto postfix and prefix. Pointer:A B C + * D / E −,− / * A + B C D E(p. 22 to 24). - Unit 2: Build the tree with inorder D B E A F C G and preorder A B D E C F G. Pointer: root A; postorder D E B F G C A (p. 38).
- Unit 3: Why does Dijkstra fail with negative edge weights? Pointer: finalised vertices are never updated; use Bellman-Ford (p. 65).
- Unit 4: Show polyphase merge for 21 runs on 3 tapes. Pointer: 13 and 8 runs, six phases (p. 87).
More practice sits in the MCA-102 important questions.
Sequential, index sequential and relative file organisation: excerpt from page 80 of the MCA-102 notes
Excerpt from page 80
A file is a collection of related records kept on secondary storage such as a disk or tape. A record is a group of fields, and the field that identifies each record uniquely is the primary key. File organisation is the way records are laid out on the device, and it decides how quickly a record can be reached, added or removed.
1. Sequential file organisation
Records are stored one after another, usually in primary-key order. To reach the 500th record, the first 499 have to be read. Magnetic tape is the typical medium.
- Advantages: simple; efficient for batch jobs where most records are processed, such as payroll or billing; no wasted space; cheap storage on tape.
- Disadvantages: random access is slow, O(n); inserting or deleting means rewriting the whole file (old master plus transaction file gives a new master); unsuitable for interactive queries.
2. Index sequential file organisation (ISAM)
Records are kept in key order inside blocks, and an index stores the highest key of each block with its address. To find a record, search the index, jump to the block, then scan inside that block. Both sequential and random access are possible.
- Components: a prime (data) area, an index area (track and cylinder, or multi-level) and an overflow area for new records that do not fit in their block.
- Advantages: fast random access while sequential processing still works; suits applications that need both, such as bank accounts or student records.
- Disadvantages: extra space for the index and overflow; performance drops as the overflow grows, so the file needs periodic reorganisation. B+ tree files from Unit 2 are the modern replacement.
3. Relative (direct or random) file organisation
Each record sits at a relative record number, its slot position from the start of the file, worked out from its key either directly or through hashing. Because the address is calculated, the record is reached in one access with no searching. This needs a direct-access device such as a disk. The byte address is the relative record number multiplied by the record size, counted from the start of the file.
Do the MCA-102 notes cover the full GGSIPU syllabus?
Yes. Every official topic in all four MCA-102 units has a matching section in the notes; no gaps were found.
| Official unit | Official topics | In the notes | Status |
|---|---|---|---|
| I: Introduction to Linear Data Structures | ADT, arrays, sparse matrices, searching, six sorts, linked lists, polynomial arithmetic, stacks, queues, Polish notations, quick sort, recursion | 1.1 to 1.9, pp. 5 to 28 | Covered |
| II: Non Linear Data Structures: Trees | Binary trees, BST, traversals, threaded tree, tries, AVL, B, B+ and B* trees, heaps | 2.1 to 2.9, pp. 32 to 51 | Covered |
| III: Non-Linear Data Structures: Graphs | Representation, BFS, DFS, MST, shortest paths, topological sort, case studies | 3.1 to 3.7, pp. 55 to 71 | Covered |
| IV: Hashing and File Structures | Hashing, collision resolution, file organisation, files in C, external sorting | 4.1 to 4.7, pp. 75 to 88 | Covered |
MCA-102 official topics mapped to the notes
- Official unit
- I: Introduction to Linear Data Structures
- Official topics
- ADT, arrays, sparse matrices, searching, six sorts, linked lists, polynomial arithmetic, stacks, queues, Polish notations, quick sort, recursion
- In the notes
- 1.1 to 1.9, pp. 5 to 28
- Status
- Covered
- Official unit
- II: Non Linear Data Structures: Trees
- Official topics
- Binary trees, BST, traversals, threaded tree, tries, AVL, B, B+ and B* trees, heaps
- In the notes
- 2.1 to 2.9, pp. 32 to 51
- Status
- Covered
- Official unit
- III: Non-Linear Data Structures: Graphs
- Official topics
- Representation, BFS, DFS, MST, shortest paths, topological sort, case studies
- In the notes
- 3.1 to 3.7, pp. 55 to 71
- Status
- Covered
- Official unit
- IV: Hashing and File Structures
- Official topics
- Hashing, collision resolution, file organisation, files in C, external sorting
- In the notes
- 4.1 to 4.7, pp. 75 to 88
- Status
- Covered
Official source: MCA (02 Years) Scheme of Examination & Detailed Syllabus, A.S. 2025-26 onwards.
These MCA-102 Data and File Structures IPU notes keep the textbook unit split. Every course in GGSIPU notes is mapped to its official PDF this way.
Who writes and checks the MCA-102 DFS notes?
- Prateek Talwar, author: Founder, Unnati Educations; Associate Company Secretary (ACS), ICSI, membership no. 58704, since 15 May 2019; B.Com, University of Delhi (School of Open Learning), 2012. Author profile
- Ritik Rawat, subject reviewer: Senior Full Stack Developer, Unnati Educations; B.Tech.
The 2026-27 edition follows the MCA scheme approved on 01 August 2025. Last updated 13 October 2026; see the editorial policy.
The same team prepares GGSIPU important questions for every course.
MCA-102 and the MCA-162 Data and File Structures lab, plus other GGSIPU MCA Sem 2 papers
Paired lab: MCA-162 Data and File Structures lab notes, L 0, P 2, 1 credit.
MCA-162 outcomes map to theory units:
- CO1 to CO3 (arrays, lists, stacks, queues, sparse matrix, polynomials, searching, sorting) → Unit 1.
- CO4 (BST) → section 2.3.
- CO5 (graph algorithms) → Unit 3.
- CO6 (binary-file application) → section 4.6.
Other Semester 2 papers: MCA-104 Object Oriented Software Engineering and MCA-106 Python Programming (compulsory theory).
Core Elective I, one of: MCA-108 Advanced Database Management Systems, MCA-110 Data Warehousing and Data Mining, MCA-112 Mobile Applications Design and Development, MCA-114 Full Stack Development, MCA-116 Web Technologies, MCA-118 Theory of Computations, MCA-120 Software Testing, MCA-122 Microprocessors, MCA-124 Embedded System, MCA-126 Information Security.
Open Elective I, one of: MCA-128 Digital Marketing, MCA-130 Management Information System, MCA-132 Management Principles and Organizational Behavior, MCA-134 Finance and Accounting. Labs MCA-164 to MCA-168, MCA-170 Minor Project II, and NUES courses MCA-172 and MCA-174 complete the term.
How to write MCA-102 answers: address numericals, algorithm traces and twelve-mark C function answers
The MCA-102 paper has a compulsory 12-mark Q1 of short answers from all four units, then one 12-mark question per unit with subparts. That pattern rewards three answer types the notes practise again and again: address-calculation numericals, step-by-step algorithm traces, and short C functions with a line on complexity.
- Numericals. Write the formula first, then the bounds, then substitute. The Common Mistakes table warns that row-major multiplies by the column count N and column-major by the row count M.
- Traces. Draw the table the notes use: pass-by-pass arrays for sorts, the queue or stack after each step for BFS and DFS, a dist row per picked vertex for Dijkstra, and probe sequences with collision counts for hashing. State the neighbour order before a BFS or DFS, and mark a BFS vertex visited when it is enqueued, not when it is dequeued.
- C functions. Keep code to the core function, comment the line that matters (such as
p->next = q->next;beforeq->next = p;in list insertion), and finish with best, average and worst complexity. For Floyd-Warshall, writekas the outer loop; for quadratic probing, use h + i², not h + 2i.
Worked example: array address with negative bounds
An integer array A[−5 … 20] at base 2000 with 4-byte elements has 20 − (−5) + 1 = 26 elements, and A[10] sits at 2000 + 4 × (10 − (−5)) = 2060. Showing (i − LB) as 15 is where marks are kept.
For trees, state your level convention once. Practise this format on GGSIPU MCA important questions.
MCA-102 DFS notes FAQs
How do I get the full MCA-102 notes?
Tap the "Get Full Notes" button at the top of this page or the order button at the end. It opens WhatsApp with your paper code already typed, so the team knows you want the MCA-102 book. The team shares price and payment details in the chat; the printed book reaches you within 5 to 7 days at most, depending on your location.
Are the MCA-102 notes available as a PDF?
No. The complete MCA-102 notes are sold only as a printed book, not as a PDF. You can still check the layout first: the "View Sample PDF" button at the top opens a watermarked set of seven pages, including the cover, the index and one content page from each unit. All 90 pages come in the book.
What is the passing mark for MCA-102 in GGSIPU?
MCA-102 is marked out of 100, and its end-term paper totals 60 marks: a 12-mark compulsory Q1 plus four unit questions of 12 marks each. The MCA scheme of examination states pass marks as 40 out of 100 for every paper. It does not print the internal and end-term split, so check end-term minimums and re-appear rules in Ordinance 11 on ipu.ac.in.
Which MCA-102 unit has the most C code?
Units 1 and 2 have the most, with 22 C listings each. Unit 1 holds the sorting, list, stack and queue code; Unit 2 the BST, traversal, trie, AVL and heap code. Units 3 and 4 have 12 each, but Unit 3 has the most with run output (7), from BFS and DFS to Dijkstra and Floyd-Warshall.
Do the MCA-102 notes follow the 2025-26 MCA scheme?
Yes. The MCA-102 notes follow the MCA (02 Years) scheme for affiliated institutes that applies from academic session 2025-26, approved on 01 August 2025. All four units keep the official order and topic list, including the Unit 3 graph case studies and Unit 4 external sorting. The syllabus map above gives the page for each topic.
Can the MCA-102 theory notes help with the MCA-162 lab?
They help with the logic. The MCA-102 notes include 24 C listings with actual run output, such as sparse matrix transpose, polynomial addition, BST operations, graph algorithms and binary file records, which match several MCA-162 course outcomes. Use them to understand the logic, then write and run your own programs; MCA-162 lab notes are a separate book.
Get the full MCA-102 Data and File Structures Notes on WhatsApp
These Data and File Structures notes in English come as one printed book, not a PDF.
Inside: 68 C listings, 16 solved examples, 32 figures and 88 practice questions. Price and payment details are shared on WhatsApp. Delivery: within 5 to 7 days at most; the exact time may vary with your location.
Order the MCA-102 notes book on WhatsApp (4 units, 90 pages)
Unnati Educations is an independent education provider based in Vikaspuri, Delhi. We are not affiliated with, authorised by, or endorsed by Guru Gobind Singh Indraprastha University (GGSIPU). 'GGSIPU' and 'IPU' are used only to describe the syllabus our notes follow. For official information, visit ipu.ac.in.
Ready for the full notes?
Discuss coverage and delivery with our team.