Problem #253
Another Board Game
Annu wanted to invent a board game to play with his girlfriend Chunnu on their next date. He came across the following problem while trying to look for optimal coloring for his board game.
Consider an N\times N board where each cell can be coloured black or white. Let x_i denote the number of white cells in the ith row and y_j denote the number of white cells in the jth column. Define f(N) as the maximum possible value of the sum: \sum_{i=1}^{N} x_i\cdot(N - y_i)
Calculate f(13579).