-2

You want to organize a party and invite as many of your N friends as possible so that the following condition is met: at a party, everyone invited must know at least three other guests and must not be familiar with at least three other guests. The input to the problem is number N and the list of pairs (i, j) where i and j know each other. What would be an efficient algorithm that implements the above mentioned and what's the complexity? Could I use some greedy approach?

1 Answers1

2

Hint: It's actually quite simple.

(Yes, that's all the hint you need).

gnasher729
  • 32,238
  • 36
  • 56