For all n≥2 we have f(n,1)=1, since any two 1-element sets are neighbours. So for all n≥2 and k=1 the statement holds. We will prove the general statement by induction by n, taking the base case to be n=2. We will assume that the statement holds for n−1 and consider the n-element set S={1,2,…,n}. Let 1<k≤n−1. The number of k-element subsets containing the number n can be at most f(n−1,k−1) in a neighbour-free collection, since removing the number n from all of those subsets yields a neighbour-free collection of k−1-element subsets of {1,2,…,n−1}. The number of k-element subsets not containing n can be at most f(n−1,k). Therefore f(n,k)≤f(n−1,k−1)+f(n−1,k). By the induction assumption f(n−1,k−1)≤(k−2n−2) and f(n−1,k)≤(k−1n−2). Therefore by Pascal's rule f(n,k)≤f(n−1,k−1)+f(n−1,k)≤(k−2n−2)+(k−1n−2)=(k−1n−1), as desired.