in reply to Sub set where all are connected

Perhaps you are looking for cliques in a Graph? Which are defined as the subset of nodes/items which are all connected to each other. Now this is a hard problem. Perl module maybe Graph::Clique if you know the size of clique you are looking for.

bw, bliako

Replies are listed 'Best First'.
Re^2: Sub set where all are connected
by ikegami (Patriarch) on Nov 23, 2019 at 01:03 UTC

    The find the largest cliques, one could use the following:

    Update: Nevermind, completely wrong.