Which java keyword is used to import a class
Answers
Explanation:
HEYA USER
HERE'S YOUR ANSWER
The java keyword- import is used to import classes.
It is used to import all inbuilt and user defined packages into the java source file .
HOPE IT HELPS
MARK IT AS THE BRAINLIEST
Answer:
Short notes on import statement:
In Java, Import statement is used for referring either all the classes & interfaces of the specific package (or) a specifying about particular class/interface of a specific package in our java program.
Syntax:
(i) import package1.package2.....*;
It is used to import all the predefined properties of specific package.
(ii) import package1.package2....classname/interfacename;
It refers either one class (or) one interface of a specific package but not all.
Advantages of 'import':
(i) Easier to provide access control.
(ii) Name conflicts i.e Name space collision is avoided.
(iii) Reusability.
Hope this information helps!