CS201 Final term short notes.pdf

Verified academic study resource for CS201 (Introduction to Programming) under the Computer Science at Virtual University of Pakistan. This PDF document (Final-Term Solved Past Paper & Examination Pack) covers Final-Term Exam Scope (Lectures 23 to 45) spanning approximately 320 pages across 4 curriculum modules, and is indexed for student examination review with instant in-browser preview and 100% free direct download.

Course
CS201 – Introduction to Programming
Faculty
Computer Science
Format
PDF
Type
Final-Term
Coverage
Final-Term Exam Scope (Lectures 23 to 45)
Tags
FINALTERM

Virtual University regulations strictly require achieving at least 20% marks in the Final-Term exam paper alone (typically 12+ marks out of 60) to pass CS201, regardless of midterm scores.

What this file covers — CS201 syllabus roadmap

  1. Object-Oriented Paradigms: Classes & Data Abstraction — Lectures 23 to 29 (Pages 281 to 360). 16% Final-Term Marks (Core OO Concepts)
  2. Inheritance Hierarchies & Dynamic Polymorphism — Lectures 30 to 36 (Pages 361 to 435). 20% Final-Term Marks (Virtual Functions & V-Tables)
  3. Templates, Standard Library & Persistent File I/O — Lectures 37 to 41 (Pages 436 to 510). 14% Final-Term Marks (Generic Code & Streams)
  4. Final-Term Examination Dossier & Capstone Synthesis — Lectures 42 to 45 (Pages 511 to 585). Final-Term Exam Synthesis (Lectures 23–45 Scope)

Frequently asked questions

Where can I download CS201 Final term short notes.pdf for free?

You can preview and download "CS201 Final term short notes.pdf" (CS201 PDF, ~320 pages) directly from the MIHORA VU Study Library (https://study.mihora.tech/doc/cs201-final-term-short-notes-pdf) with 100% free high-speed downloads and zero registration requirements.

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

This document covers Final-Term Exam Scope (Lectures 23 to 45) across 4 distinct lecture units (Lectures 23 to 29, Lectures 30 to 36, Lectures 37 to 41, Lectures 42 to 45), featuring comprehensive definitions, solved objective questions, and examiner marking rubrics.

What is the passing criteria for CS201 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 CS201 solved past papers and handouts verified for 2026 exams?

Yes. All CS201 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

                                     Cs201
             Short notes for final term
         Provide BY Orange Monkey Team
Lecture 23 to 25
Pre-processor:

       Macros with the #define directive. Micro is a special name, which is
substituted in the code by its definition and as a result, we get an expanded code.

#define PI 3.1415926

Directive:

Directive is a language construct that specifies how a compiler should process its
input

Macro:

Macro is a fragment of code which has been given a name.

Memory Allocation:

Memory allocation refers to performing manual memory management for dynamic
memory allocation in the C programming language via a group of functions in the
C standard library realloc, calloc etc.

Dangling Pointers:

Dangling pointer occurs at the time of the object destruction when the object is
deleted or de-allocated from memory without modifying the value of the pointer.

History of C/C++:

C language was developed by scientists of Bell Labs in 1970s. It is very lean and
mean language, very concise but with lot of power. C conquered the programming

world and took it by storm. Major operating systems e.g., Unix was written in C
language.

Structured programming:

C is called structured modular programming language because while solving large
and complex problem, C programming language divides the problem into smaller
modules called functions.

Inline functions:

This is also one of the facilities provided by C++ over C. In our previous lectures,
we discussed and wrote macros few macros like max and circlearea. Inline
functions also work more or less in the same manner as macros.

Lecture 26 to 45
Q.1. What is OOP(Object Oriented Programming)

Ans. Object Oriented Programming is a computer programming model that
organizes software around data or subject rather than features or logic. An object
can be defined as a data that has a unique attribute and behavior

Q.2. What is Core?

Ans. The core of the pure object oriented programming is to create an object. In
code, that has certain properties and method.

Q.3. What is class?

Ans. A class is a user defined data type, which holds its own data members and
member functions, which can be accessed and used by creating an instance of that
class

E.g: Consider the class of Cars

Q.4 How many types of class?

Ans. There are two types of classes

    1. Abstract classes
    2. Concrete Classes

Q.5. What is Abstract Classes?

Ans. Not object is made, Only inheritance can be used that have abstract and
concrete methods, real words existence are not found. Abstract class can not be
instantiated using new keyword. Abstract class may or may not have abstract
method

Q.6. What is concrete methods?

Ans. Object is made and used, derived and child classes from abstract classes ,
real words existence are found. Concrete class can be instantiated using new
keyword. Concrete class can not have an abstract method

Q.7. What is abstraction or Information hiding?

Ans. Data abstraction refers to provide essential information to the outside the
world but hide their background details. i.e to represent the information needed to
the program without presentation the details

For Example: The data base system hides detials how data is stored and created
and maintained.

Q.8 What is Encapsulation?

Ans. Encapsulation is placing the data and function work on that data in the same
place. Only works with procedural languages.

 It is not always clear which works on which variables but object oriented
programming provides you framework to place the data that works together in the
same object.

Q.9 What is inheritance?

Ans. One of the most useful aspects of object oriented programming is code
reusability. Inheritance is the process of forming a new class from an existing class
that is:

New class is called as derived class and Existing class is called as base class.

Q.10. What is the features to reduce the code size in OPP?

      Public inheritance
      Protected
      Private

Q.11. What is Polymorphism?

Ans. Poly refers in many. This is a single function or an operator functioning in
many ways different upon the usage is called Polymorphism.

Q.12. What is overloading?

Ans. Is the branch of polymorphism. When existing function is made to operate on
new date type, it is said to be overloading

      Function overloading
      Operator overloading
      Overloading vs overloading

Q.13. What is constructor?

Ans. We have written a function named Date(int, int, int). This is in the public
section in our class. It has no return type having the name as that of class. Such
function are called constructor.

Q.14. What is friend function?

Ans. A friend function that can access protected, private and public member of a
class. The friend function is declared using friend keyword inside the body of a
class.

Q.15. What is friend class?

Ans. Friend class is a class that can access to private and protected member of a
class which is declared as friend.

For example: This is needed we want to allow particular class to access the private
and protected member of a class.

Q.16. What is reference data type?

Ans. Unlimited numbers of reference data types, as they are defined by the user.
Consists of Boolean and numeric data type, Int, float, long, short and double

Example of reference data types are Arrays, Sting Class etc.

Q.17. What is default arguments with constructors?

Ans. A constructor can have two arguments. They are used to initialize member
objects. If default values are supplied, the trailing arguments can be omitted in the
expression list of the constructor.

Example: Defines a class with one constructor and two default constructor.

Q.18. What is operator overloading and Explain its type?

Ans. Operator overloading is quite similar to function overloading.

     There are two types of Operator overloading:

       A) Unary

       B) Binary

Unary: Unary operator requires only ones to the left of the operand on single
operator.

Example: ^, &, !

Binary: Binary operator requires two operands on both side of the operator.

Example: +, -, *, /

More CS201 files

All CS201 files · Midterm Prep 2026 · MCQs Bank