In computers, garbage has two related meanings:
1) From a user's perceptual point-of-view, garbage is often used to mean anything on your display screen that looks unreadable or unviewable. This can include looking at a graphics file, such as a Web Graphics Interchange Format file, with a text reader. Although this is simply an instance of using the wrong program to view a perfectly good file, the viewer is likely to think that what's presented is "garbage."
2) From a programming point-of-view, garbage is data that has been placed in random access memory space obtained from the operating system that is no longer needed. Freeing the space for reuse is called "garbage collecting." In the past, programmers have had to write programs that explicitly requested storage and then returned it to the system when it was no longer needed. (Programs that neglect to return unused storage can be shut down by the operating system.) The term "garbage collecting" apparently was first used in the LISP programming language. Java is a newer programming language that, like LISP, handles garbage-collecting for the program, freeing the programmer from being concerned about it.