Stack Exchange network consists of 176 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
This is an elementary problem which seems difficult, and I'm not sure whether it could be solved out. A higher mathematics overlook might be needed.