I am new to Graph Theory. I am trying to understand the relationship between Strongly connected graphs and Strongly connected components(SCC). Please explain why if there are k SCCs in a graph, we can add atmost 2k edges to make the graph a strongly connected one.

What I have tried:

My intuition is that for a graph to be strongly connected each vertex should have at-least one incoming edge and one out going edge. So, if there are k SCC, they can generate a cycle among themselves by adding 2 edges to adjacent SCC - 2k edges. I am not sure if my intuition is correct and if it is how can I logically implement this in an algorithm.

O(n) algorithms for finding strongly connected components are referenced here[^].

I think your intuition is correct. However, the wording "we can add at most 2k edges to make the graph a strongly connected one" is confusing. In many such graphs, you can add more than 2k edges without making the graph strongly connected. For example, if an SCC only contains a one-way cycle, all the edges in the opposite direction could be added without connecting any SCCs at all. The statement should therefore be that "up to 2k edges may have to be added to make the graph strongly connected". But those edges must be chosen the way that you describe.