hash,search and sort problems