You are on page 1of 5

Introduction to OOP

abelski
02/02/09 2009 Haim Michael. All Rights Reserverd. 2
Introduction
02/02/09 2009 Haim Michael. All Rights Reserverd. 3
Procedural Programming
The procedural programming, also known as imperative
programming, refers to software programming approach in
which the instructions are listed step by step.
Using a procedural programming language the programmer specifies the exact
language statements to perform one after the other.
int num_a = 4;
int num_b = 8;
int sum = num_a + num_b;
if(sum>10)
{
...
}
02/02/09 2009 Haim Michael. All Rights Reserverd. 4
Obect Oriented Programming
The Obect Oriented Programming !"#" $OOP%& is a
programming paradigm that uses $obects% and their
interactions with each other to design software applications.
Till early '(()s the OOP paradigm wasn*t wide supported. Today most programming
languages !e.g. +ava, ,-, ,.., P/P& support it.
Person per_a = new Person(i!"ae#$%1&'&1&4'1&');
Person per_b = new Person((ane$%4')'4)&'4');
Person per_! = new Person(*a+i,$%4)&'4&'41);
per_a.a,,-rien,(per_b);
per_a.a,,-rien,(per_!);
02/02/09 2009 Haim Michael. All Rights Reserverd. 5
Obect Oriented Programming
Person per_a = new Person(i!"ae#$%1&'&1&4'1&');
Person per_b = new Person((ane$%4')'4)&'4');
Person per_! = new Person(*a+i,$%4)&'4&'41);
per_a.a,,-rien,(per_b);
per_a.a,,-rien,(per_!);
0ichael
+ane
1avid
1&'&1&4'1&'
4')'4)&'4'
4)&'4&'41

You might also like