author and iconoclast
posted 13 years ago
Well, there are no "Bag" classes in the standard Java APIs, and List is an interface, which you can't instantiate. Stack is a concrete class, though. It (along with all the other Collections classes) is in the java.util package, so "import java.util.Stack;" would let you create one in your program. Read the javadocs for the classes in that package -- there are lots of interesting ones!