Prove that for a bipartite graph $G$ on $n$ vertices the number of edges in $G$ is at most $\frac{n^2}{4}$.
I used induction on $n$.
Induction hypothesis: Suppose for a bipartite graph with less than $n$ vertices the result holds true.
Now take a bipartite graph on $n$ vertices.Let $x,y$ be two vertices in $G$ where an edge exist between $x$ and $y$. Now remove these two vertices from $G$ and consider this graph $G'$. $G'$ has at most ${(n-2)^2}\over4$. Add these two vertices back. Then the number of edges $G$ can have is at most
$$|E(G')|+d(x)+d(y)-1$$
My question is in my proof I took $d(x) + d(y) \le n$, where $d(x)$ denotes the degree of vertex $x$. Can I consider $d(x)+d(y) \leq n$? I thought the maximum number of edges is obtained at the situation $K_{\frac n 2,\frac n 2}$