EDITABLE CODE:
LiveDemo:jQuery - Determining Content of jQuery Object
Note:The scope (i.e context) of the jQuery is the element UL.