3 ms·
Unless I missed something, it matches if you don't treat it as a directed graph. Edge (1,6) accounts for both (1,6) and (6,1) in that case.
by Jtsummers 10y ago
Unless I missed something, it matches if you don't treat it as a directed graph. Edge (1,6) accounts for both (1,6) and (6,1) in that case.
- awesomepantsm 10y agoYou didn't miss anything. This is why these are good interview questions, because it weeds out the people who are asleep.