exercise in creating a tube class