- When you create a class in Java, it automatically inherits from the Object Class.
- However, in C++, there is a forest of classes; when we create a class that does not inherit from another, we are creating a new tree in the forest.
- The Test class inherits from the Object class by default, as shown in the Java example.
Shathana. S.R. Answered question May 29, 2023
