Leads, Contacts and Deals can be sorted by common fields (First Name, Last Name, Date Added, etc) and custom fields. One way to use the sorting functionality is to sort by Last Activity.
What is considered activity?
An activity is logged any time there is a new email sent, task, note, or call associated to a contact, deal or lead. An activity is also logged whenever there is an edit to any of these records.