About objects
Every object has certain Methods and properties
Methods:
I want to give practical example, Friends are best example
for Methods, and if u asks something they will do.
Technically you ask u r friend please add
int x=5,y=3;
(Now u r calling): freind-add(int x,int y);
Freind-add (int x, int y)
{
int c=x+y;
printf("%d",c);
}
he completed adding.
Note: Above example assume u r freind name is freind-add
similarlly you ask u r freind please subtract (Now u r
calling):
int x=6, y=3;
(Now u r calling):freind-subtract(int x,int y)
freind-subtract(int x,int y)
{
int c=x-y;
printf("%d",c);
}
Another freind completed subtracting.
In java script you can see objects like button, textbox ....
these are called objects.similarly button has some methods.
Click,Double click are some methods for button object
About Properties
These buttons has some properties: Height,Width,back color
Properties means it defines about object.How they look like.
See like human beings i am tall(6 feet),good eyes(Blue eyes) ... these are
called
properties
No comments:
Post a Comment