What does the problem statement mean…???
CompetitiveProgramming/Challenges-Graphs/Vivek and Birthday Celebration
Hi
we have to tell minimum number of friends we can invite given the dependency
and dependency is that:
two integers, a and b - which would represent that friend a wouldn’t come to the party until and unless friend b is also invited
it means that if we invite a friend a then before invite we should have b in the invite list.
in this constrained situation we have to tell minimum number we can invite.
for eg take a test case:
3 2
1 2
2 3
answer would be 1 (invite only 3)
Hit like if you get it!
cheers!
Thanks!!!..problem solved…
I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.
On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.
Can you please elaborate a bit more ?
Thanks
the ans for this case will be 2 ( inviting 3 will invite 2 and total members are 2 ) . please update the comment , it’s misleading