Comment: C++ "includes" behavior and java "imports"

Answer Posted / chaitanya

fine...........
in C++ we wrote #include<@@@@@@@@@>
because it accessing the functions,keywords....etc from
that header file.
But in Java we imports the classes i mean....
inherits the behaviour of that imported class
ex: import java.*;
the properties(all functions,...etc data) of the java class
will comes to what classes we wrote in the program.


FROM:
MICHAEL JACKSON(King Of Pop)

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

If a method definition has been specified in the base class and the interface which the class is implementing, which definition will be picked if we try to access it using interface reference and class object?

704


Does java support multiple inheritance? if not, what is the solution?

723


What is the benefit of using inheritance?

801


What is the order of call of constructors in inheritiance?

788


Explain persistence?

753


What is the syntax of object oriented method call?

730


Can we override static methods of a class?

723


What if we override the conflicting method in the class?

717


What are the access modifiers?

785


What is the difference between an interface and abstract class?

799


Why abstraction is important?

792


What is the difference between multiple and multilevel inheritance?

771


Write down how will you create a Binary tree?

775


What are the various types of constructors?

781


Can a class in java be inherited from more than one class?

684