This comet formed at very edge of the solar system ... out by pluto ... and spent all its lifetime out there until recently it came into the inner part of the solar system, where we could sample it.
In recent decades, spacecraft have passed fairly close to comets and provided us with excellent data. Stardust, however, marks the first time that we have ever collected samples from a comet and brought them back to Earth for study.