ḥ - Hash
Tags: array , number
This atom is dyadic, which means it takes two arguments.
Jelly's Hash Function. Given a magic number (like a salt) and an input, yield a value from a collection.
x contains a magic number, similar to a salt (tt can also be a base-250 compressed integer in string form), concatenated with a collection of values. If
x has more than two values, the first is the magic number and the remainder of the list is the collection. If the second value if
x is a number
N, it is converted into
[1, 2, ..., N]. Then,
y is used as input to the hash function. An item from the collection is returned based on this hash. The hash function is defined in