Hacker Timesnew | past | comments | ask | show | jobs | submitlogin

The notation and its meaning are both pretty clear, but I don't see how it converts to "the set of all permutations from 1 to N". And permutations of what? The integers 1 to N?


Permutations of the integers 1 to N, yes.

You can look at each permutation as a (unique, one-to-one and onto) function from the set [1,2,3,...N] to positions labeled also [1,2,3,...N]. For it to be a permutation, each position needs to contain a single value, and each value needs to be at one single location. Since the domain and range of the function have the same (finite) number of elements, either of these properties implies the other.


I guess that's why he talks about applications and not functions, so that guarantees there is a single x for each y.


I think he was just clarifying a point about the notation.

Given that each f is a function, mapping each member of its domain to one member of its range, and that for each member of the range, there is a member of the domain that the given function maps to it, and that the domain and range are the same size, then there can be no member of the domain not mapped to some member of the range, and each member of the domain must be mapped to a distinct member of the range (or else there would not be enough members of the domain to cover all the members of the range), so, with the domain and range being the same set, each of the given functions is a permutation of the domain, and collectively they must be all of them.

This is a verbose version of the argument for this being the set the author says it is. Arguably, it would be easier to read if I had used x for 'member of the domain', y for 'member of the range' and f for 'the given function'.




Consider applying for YC's Summer 2026 batch! Applications are open till May 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: