I have 2 different but similar problems, one belongs to NP and one to L and I don't understand why.
First problem: Input: an undirected graph G with n^2 vertices. Question: Is there exist in G a matching of size n AND an independent set of size n?
Second problem: Input: an undirected graph G with n^2 vertices. Question: Is there exist in G a matching of size n OR an independent set of size n?
The AND problem is in NP and the OR problem is in L. Can someone explain why? Thanks.