Added voting, and improved sorting.