I apologize for the stupid/newbie question, but…

I’m having difficulty getting the distance between all possible curves end points. Getting the distance between two curves is easy, but cloud curves are far more difficult. I don’t know how to produce the list with all possible points combinations and how to interact with the first point (basic) list?

Is there a component for that?

Can you help me with suggestions?

Thank you in advance