Object Oriented Programming • TIT-244
- Course Instructor: Dr. Ratnesh Srivastava.
Click on the links to start the direct download (for Windows x64).
- Visual Studio Code: IDE / Code editor of choice. Allows to install “extensions” for various languages and tools, without needed separate IDE for every programming language. Performant & lightweight. Available for all desktop platforms. Syntax highlighting works even without these extensions. Visual Studio Code is from Microsoft & available under open-source license.
- Python: Python interpreter/runtime for running Python scripts/programs & Python Package Manager (pip) for installing external libraries (
python
/python3
/pip
/pip3
).
- TDM GCC: A minimal GNU C/C++ compiler toolchain for Windows (
gcc
/g++
).
- Java Development Kit: Java runtime & compiler (
java
/javac
).
- Git for Windows (optional): Source-code management & version control (
git
).
Assigments
- Assignment 1: Write a program to take a list of 10 farmers, fruits they sell, their cities & the quantity of fruits they have as input. Save the data to notepad before & after sorting based on quantity in tabular manner. Also perform search operation based on farmers’ name.
- Assignment 2: Write a program to take quantity & quality of fruits Mango, Apple & Papaya as input. Quality may be good, bad or average. If entered quantity of fruit is greater than 1000, store it as half. Perform search for a given fruit with given quality.
- Assignment 3: There are four orchards, namely A, B, C & D with fruits in them as Apple, Litchi, Mango, Apple respectively. The qualities of the fruits in the orchards are good, good, good & bad respectively. Based on that: 1. The available orchards in a tree-view. 2. Search for a given fruit in the available orchards after taking input from the user & print the tree.
- Assignment 4: Take or make a map of any building & generate a graph.
- Assignment 5: Take a map provided as a graph & display all the subtrees of connected points.
- Assignment 6: Enter entry point & goal point & produce the matching subtree of the graph.
- Assignment 7: Give the weightage for each edge of nodes, and produce the shortest path from start to end node.
- Assignment 8: Write a program to demonstrate the use of all keywords made for exception handling.
- Assignment 9: Write a program to demonstrate the use of only
throw
keyword.
- Assignment 10: Write a program to demonstrate the use of only
try
& catch
keywords.
- Assignment 11: Write a program to demonstrate the use of only
throws
keyword.
- Assignment 12: Write a program to withraw money from a bank account, if the withdrawn money is greater than the balance, then it throws
NoMoneyException
.
Classroom Discussion
- Introduction, programming & programming languages, objects & types of objects.
- Tags:
programming
, object
.
- Object, data-types, user-defined data types, object & instances, references & pointers, fundamental concepts of OOPs, abstraction.
- Tags:
object
, data-types
, class
, struct
, pointer
, references
, fundamentals
, abstraction
.
- Encapsulation, access-modifiers, inheritence, types of inheritence.
- Tags:
encapsulation
, access-modifiers
, inheritence
, generalization
, composition
, aggregation
.
- Inheritance, polymorphism, run-time-polymorphism, compile-time-polymorphism, diamond-problem.
- Tags:
inheritence
, overriding
, overloading
, diamond-problem
, abstract
, interface
.
- Problem: There are employees of two kinds A & B. A is a government employee and B is a private employee. A gets a basic salary & DA, whereas B gets a basic salary & gets a fixed commision for the given amount of sales. Write a program to show the name & total salary of employee of each kind. Let,
Kritika
is category A employee & Sumit
is a category B employee.
- Tags:
interface
, runtime-polymorphism
, uml-diagram
.
- Problem: A company has its own customers, who place orders for a particular product with its cost. Company also has its own stores for different products. Company delivers the products to the customers from the stores by a delivery boy. Write a suitable program using object oriented programming language.
- Tags:
object-relationship
, one-to-one
, many-to-one
, references
.
- Object Relations, SOLID Principles, Tight-Coupling
- Tags:
one-to-one
, many-to-one
, unidirectional
, bidirectional
.
- Exceptions & Errors, Compile-Time & Run-Time Exceptions, Exception Handling Keywords, Exception Chaining
- Tags:
exception
, error
, compile-time
, runtime
.
- Thread, Mutual-Exclusion, Lifecycle Of A Thread, Publish-Subscribe Algorithm, Synchronization
- Tags:
thread
, lifecycle
, mutual-exclusion
, synchronization
, ownership
.