CS402 Mid Term Past Paper 1.pdf

Verified academic study resource for CS402 (Theory of Automata) under the Computer Science at Virtual University of Pakistan. This PDF document (Midterm Solved Past Paper & Revision File) covers Mid-Term Exam Scope (Lectures 1 to 22) spanning approximately 240 pages across 4 curriculum modules, and is indexed for student examination review with instant in-browser preview and 100% free direct download.

Course
CS402 – Theory of Automata
Faculty
Computer Science
Format
PDF
Type
Midterm
Coverage
Mid-Term Exam Scope (Lectures 1 to 22)
Tags
PAST-PAPER, MIDTERM

Focus on core definitions and repeated MCQs from Lectures 1–22. Remember that scoring in the First Half builds your safety buffer toward the mandatory 20% Two-Half passing rule in CS402.

What this file covers — CS402 syllabus roadmap

  1. Core Architecture, Syntax & Primitive Data Structures — Lectures 1 to 6 (Pages 1 to 65). 15% Objective Marks (8–10 MCQs)
  2. Conditional Branching, Loops & Logical Control Flow — Lectures 7 to 12 (Pages 66 to 140). 18% Exam Marks (MCQs + 2-Mark Short Questions)
  3. Memory Management, Pointers, Arrays & Functions — Lectures 13 to 18 (Pages 141 to 215). 22% Exam Marks (High Yield for Midterms)
  4. Midterm Consolidation, Strings & Algorithm Synthesis — Lectures 19 to 22 (Pages 216 to 280). Midterm Exam Culmination (Lectures 1–22 Scope)

Frequently asked questions

Where can I download CS402 Mid Term Past Paper 1.pdf for free?

You can preview and download "CS402 Mid Term Past Paper 1.pdf" (CS402 PDF, ~240 pages) directly from the MIHORA VU Study Library (https://study.mihora.tech/doc/cs402-mid-term-past-paper-1-pdf) with 100% free high-speed downloads and zero registration requirements.

What syllabus chapters and lectures are covered in this CS402 file?

This document covers Mid-Term Exam Scope (Lectures 1 to 22) across 4 distinct lecture units (Lectures 1 to 6, Lectures 7 to 12, Lectures 13 to 18, Lectures 19 to 22), featuring comprehensive definitions, solved objective questions, and examiner marking rubrics.

What is the passing criteria for CS402 under the VU 20% Two-Half Rule?

Under official Virtual University regulations, students must score at least 20% in the First Half (Quizzes, Assignments, GDBs, and Midterm combined) AND independently at least 20% in the Final-Term examination paper. Scoring under 20% in the final exam results in an automatic F grade regardless of earlier marks.

Are CS402 solved past papers and handouts verified for 2026 exams?

Yes. All CS402 materials on MIHORA VU—including Moaaz, Waqar Siddhu, and team archives—are reviewed against the current VU syllabus to help students prepare for 2026 Midterm, Final-Term, and online quiz examinations.

Inside this file

           FOR MORE PAPERS, GO TO VUINSIDER.COM

CS402                                                           Mid Term

Σ={a,Aa,Abb}, then string aAaAbbAa has ________ length.

      ► One

      ► Two

      ► Three

      ► Four (Page 4)

Languages generated by kleene star are always ______________.

      ► Finite

      ► Infinite (Page 7)

      ► Sometimes finite & sometimes infinite

      ► None of the these

Let S = {aa, bb} be a set of strings then s* will have

      ► Λ (Page 7)

      ► abba

      ► aabbbaa

      ► bbaab

                                                                Page 1 of 7
                       For more papers, go to VUInsider.com

           FOR MORE PAPERS, GO TO VUINSIDER.COM

CS402                                                                      Mid Term

If r1 = (aa + bb) and r2 = ( a + b) then the language (aa + bb)* will be
generated by

      ► (r1)(r2)

      ► (r1 + r2)

      ► (r2)*

      ► (r1)* (Page 10)

If a language can be expressed through FA, then it can also be
expressed through TG.

      ► True (Page 25)

      ► False

      ► Depends on language

      ► None of the above

                                                                           Page 2 of 7
                       For more papers, go to VUInsider.com

           FOR MORE PAPERS, GO TO VUINSIDER.COM

CS402                                                                     Mid Term

GTG can have _______________ final state.

      ►0

      ►1

      ► More than 1

      ► All of the given Click here for detail

In GTG, if a state has more than one incoming transitions from a state. Then all those
incoming transitions can be reduced to one transition using _____________ sign

      ►-

      ► + (Page 27)

      ►*

      ► None of the given

“One language can be expressed by more than one NFA”. This statement is
______________.

      ► False

      ► True (Page 41)

      ► Depends on NFA

      ► None of the given

                                                                          Page 3 of 7
                      For more papers, go to VUInsider.com

          FOR MORE PAPERS, GO TO VUINSIDER.COM

CS402                                                              Mid Term

If an alphabet has n number of letter, then number of strings of
length m will be

      ►n+m

      ► (n)(m)

      ►m^n

      ►n^m (Page 6)

a*b* = (ab)* this expression is __________

      ►True

      ►False

      ►Can’t be assumed

      ►None of these

Above given FA can be expressed as ________

      ► (a + b)* (Page 19)

                                                                   Page 4 of 7
                     For more papers, go to VUInsider.com

           FOR MORE PAPERS, GO TO VUINSIDER.COM

CS402                                                                     Mid Term

      ►a* + b*

      ► (ab + ba)*

      ►None of these

If a language is expressed through TG, then that language
will have its RE.

      ►True (Page 25)

      ►False

      ►Depends on language

      ►None of these

Questions:
Q1. Point of Kleen Theory.
Answer:- (Page 25)
1. If a language can be accepted by an FA then it can be accepted by a TG as well.
2. If a language can be accepted by a TG then it can be expressed by an RE as well.
3. If a language can be expressed by a RE then it can be accepted by an FA as well.

Q2. Difference and common between NFA & DFA
Answer:- (Page 25) Click here for detail
                                                                          Page 5 of 7
                      For more papers, go to VUInsider.com

           FOR MORE PAPERS, GO TO VUINSIDER.COM

CS402                                                                       Mid Term

Difference
1-In FA Finite number of states, having one initial and some (maybe none) final
states. While in NFA Finite many states with one initial and some final state.
2-In FA for each state and for each input letter there is a transition showing how
to move from one state to another while in NFA there may be more than one
transition for certain letters and there may not be any transition for certain
letters.
3-In FA is valid while in NFA is not valid.
Common
Finite set of input letters,

Q3. What is the function of mealy machine?
Answer:- (Page 60)
1’s complementing and incrementing machines which are basically Mealy
machines are very much helpful in computing.
The incrementing machine helps in building a machine that can perform the
addition of binary numbers.

Q4. Write the first step to convert GTG to FA?
Answer:- (Page 26)

                                                                            Page 6 of 7
                        For more papers, go to VUInsider.com

           FOR MORE PAPERS, GO TO VUINSIDER.COM

CS402                                                                         Mid Term

Step 1 If a TG has more than one start states, and then introduces a new start
state connecting the new state to the old start states by the transitions labeled by
Λ and make the old start states the non-start states.

Q5. Explain with example that how in GTG's we directly join the initial state
with the final state?
Answer:- (Page 27)
Eliminate the middle state and connect the first state with the last by a single
transition (include the possibility of circuit as well) labeled by the RE which is the
concatenation of corresponding two REs in the existing sequence.

                                                                              Page 7 of 7
                        For more papers, go to VUInsider.com

More CS402 files

All CS402 files · Midterm Prep 2026 · MCQs Bank