Skip to content

Instantly share code, notes, and snippets.

@filpano
filpano / gist:306556360f86b20085c8ab04809c0984
Created May 15, 2019 14:00
Set Hashcode contract violation example
import java.util.Set;
import java.util.HashSet;
import java.util.stream.Collectors;
public class HelloWorld{
public static void main(String []args){
Set<Obj> set = new HashSet<>();
Obj a = new Obj("a");
Obj b = new Obj("b");