Java is a programming language that allows code to be written once and run anywhere. It has strong security features that prevent downloaded code from infecting the system with viruses. Classes in Java are stored in separate files and only loaded when needed, which allows for faster downloading of groups of classes compressed in JAR files. Garbage collection is a form of automatic memory management that Java uses to reclaim memory instead of requiring manual deallocation.