@vaishnavi30
In Probability, events can be dependent or independent of other events.
Let's say tossing a coin two times, the probability of getting heads in either trial is 1/2. This is an independent event, where the outcome of the next trial is not dependent on the previous.
Now take an example of 2 balls (one red, one blue). The probability of getting blue in the first pick is 1/2 and the second pick would be 1 (since red was picked last time and only blue remains). These are dependent events where the probabilities change depending on the previous outcome.
Back to this question, when it says independent choosing - for choosing two nodes and finding their distance, we could pick any node as the first (1/8 probability) and the second node as we may think would be (1/7) since we have already picked the first but that's just dependent choosing and not what the question is asking. When we consider independent choosing, we can pick the first node again as the second node as well, therefore probabilities remain the same (1/8 => for both).
Hope this helps