Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Java

Kurt Daisley
Kurt Daisley
4,228 Points

PezDispenser dispenser = new PezDispenser; Variable, or Instance?

At 5:11 in the video, Chris call 'dispenser' a new VARIABLE of type PezDispenser, and at 6:13 (or so), he called it an INSTANCE of class PezDispenser instead.

I've been inserting notes/comments from what Chris says as I go along so that I understand each line of code in the exercise. I've gone over this video a couple times, and, although I think I understand the gist of it, I'd just like to get this small point cleared up. Thanks, guys.

1 Answer

Kurt Daisley
Kurt Daisley
4,228 Points

Thank you, James South! That really helps. :-)