05-04-2023, 05:34 PM
My approach is completely different. I noticed that it is sufficient to look at the left and right edges of the window separately and then combine the results. So I worked with one moving edge only which is easier. And I threw in some nice mathematics. I managed to derive a closed formula. It is all in the pdf-file:
Ofnuts_problem.pdf (Size: 136.06 KB / Downloads: 124)
The formula is rather complicated, and I don't claim that there would be no easier solutions. And I know from experience that I do make mistakes, so if you find the result useful to you, please read everything carefully and check everything.
Ofnuts_problem.pdf (Size: 136.06 KB / Downloads: 124)
The formula is rather complicated, and I don't claim that there would be no easier solutions. And I know from experience that I do make mistakes, so if you find the result useful to you, please read everything carefully and check everything.