Computer Applications
Give the reason why a class is known as:
A user-defined data type
OOP Intro Java
48 Likes
Answer
The entire data and the code, contained in an object, becomes a user-defined data type using the concept of a class. The class may be considered as a data type and an object as a variable of that data type. For example, once the Bird class has been defined, the statement
Bird parrot;
will create a parrot object belonging to the Bird class.
Answered By
26 Likes