Here you can find the source of hash(int seed, boolean x)
public static int hash(int seed, boolean x)
//package com.java2s; public class Main { private static final int PRIME = 102653; public static int hash(int seed, int x) { return firstTerm(seed) + x; }//from w ww . j a va2s. c om public static int hash(int seed, boolean x) { return firstTerm(seed) + (x ? 0 : 1); } public static int hash(int seed, Object o) { return firstTerm(seed) + (o == null ? 0 : o.hashCode()); } private static int firstTerm(int seed) { return seed * PRIME; } }