Top "Unique" questions

Refers to an element that is distinctly different from any other element in a collection.

What is the cleanest way to do a sort plus uniq on a Python list?

Consider a Python list my_list containing ['foo', 'foo', 'bar']. What is the most Pythonic way to uniquify and sort …

python unique
Django, show ValidationError in template

I create a registation app, where users can register providing a username, email and a password. What I did is …

django forms email unique validationerror
finding unique values from a list

Suppose you have a list of values x <- list(a=c(1,2,3), b = c(2,3,4), c=c(4,5,6)) I would like …

list r unique
Python: Uniqueness for list of lists

I am curious what would be an efficient way of uniquefying such data objects: testdata =[ ['9034968', 'ETH'], ['14160113', …

python unique
Do JSON keys need to be unique?

The following question is related to a question that I had asked earlier: Help parsing simple JSON (using JSON for …

java json parsing key unique
Number of non repeating lines - unique count

Here is my problem: Any number of lines of text is given from standard input. Output: number of non repeating …

bash shell line unique
Using unique constraint on Hibernate JPA2

How can I implement my unique constraints on the hibernate POJO's? assuming the database doesn't contain any. I have seen …

java hibernate unique unique-constraint
Determining duplicate values in an array

Suppose I have an array a = np.array([1, 2, 1, 3, 3, 3, 0]) How can I (efficiently, Pythonically) find which elements of a are duplicates (…

python numpy duplicates unique
MySQL select rows that do not have matching column in other table

I can't seem to figure this out so far. I am trying to join two tables and only select the …

mysql join duplicates unique
Uniq by object attribute in Ruby

What's the most elegant way to select out objects in an array that are unique with respect to one or …

ruby-on-rails ruby arrays unique