Here is a solution with 20 bits. Consider the following array: 0x000f2616, 0x000dbcce, 0x000533cf, 0x0007d943, 0x000a180c, 0x000f69f2, 0x0005e214, 0x0009da04, 0x000e101a, 0x000c495c, 0x0009cfaa, 0x000ff60d, 0x0000103d Each of these numbers $x_1,\ldots,x_{13}$ is 20 bits long. Given a hand $a,b,c,d,e$, compute the 20 least significant bits of $x_a+x_b+x_c+x_d+x_e$. You can easily check that this results in a value that identifies a hand uniquely. I found these values by randomly generating arrays until one of them worked, so it's possible that a better construction exists (such as one using codes over $\mathbb{F}_5$).