why we import both packages java.awt.*; and java.awt.event.*;
as java.awt.*; can import all classes na. then what is the
need of importing java.awt.event.*; ?
Answer Posted / shiva
writing java.awt.*; can import only the classes inside it but not its sub packages. so we need to write the sub package also.
| Is This Answer Correct ? | 20 Yes | 2 No |
Post New Answer View All Answers
Describe method overriding
How objects are stored in java?
Can we override static methods in java?
How to change value in arraylist java?
What is java string pool?
What is class and object in java?
Is hashset sorted in java?
Why is multiple inheritance not supported in java?
Where and how can you use a private constructor?
How an object is serialized in java?
What is strings in java?
What are keywords in programming?
What is a consumer in java?
What is a final class ?
What is the difference between jfc & wfc?