Alice and Friendship test
CodeChefOpen on judge ↗
Alice is doing a social experiment on friendship.She knows few basic rules about it.She knows that friendship can either be direct or indirect.She knows that direct friendship is always mutual. This means that Bob is Alice's direct friend or Alice is Bob's direct friend means the same thing. There can only be one direct friendship relation between two friends. Alice realises that making friends
HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17
CodeSearch Tutor
Hints, not spoilers — it won’t hand over the full solution unless you insist.
Sign in to chat with the tutor and save your progress.
Sign in to start