Object oriented programming terminology-
Class-
A user defined prototype for an object that define a set of attributes that characterize any object of the class.
class variable-
A variable that is shared by all instances of a class.
Data member-
A class variable or instance variable that holds data associated with a class and its object.
Instance-
An individual object of the class
Instantiation-
The creation of instance of the class.
Create class and object
program-
#create class with class attributes
class Computer():
i=10
s="This is class"
#create first object
obj1=Computer()
print(obj1.i)
print(obj1.s)
#create second object
obj2=Computer()
print(obj2.i)
print(obj2.s)
output-
10
This is class
10
This is class
-In this program, we create a class by using 'class' keyword named as Computer() that contain 2 attributes one is integer type and another one is of string.
-then we create a two object of this class and called that attributes and print that value.