Well, I need to check if there exists duplicate items inside listview on my app, but… I don’t know how.
The way to detect this is by checking the field “Tag”, if they are the same, then delete the item.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
A good way to find duplicates is to use a temporary hashset. This gives you an
O(n)O(n log n)algorithm (see Rick Sladkeys comments) to detect duplicates. Example: