What is the need for import?

I found some tutrorials in AS3. All starts with the import,
like import flash.display.*

What is the use of this? I tested the flash without putting these statements. It works.

Also there is another version of code using the document class. What is this document class?
How do I get it to work? There is a textbox in the flash main properties panel. What I do with this? Is it like putting the script externally and loading it?

I am started to AS3 yesterday.