ENG  RUSTimus Online Judge
Online Judge
Problems
Authors
Online contests
About Online Judge
Frequently asked questions
Site news
Webboard
Links
Problem set
Submit solution
Judge status
Guide
Register
Update your info
Authors ranklist
Current contest
Scheduled contests
Past contests
Rules
back to board

Discussion of Problem 2181. Student, or There and Back Again

Strange statement
Posted by 🦄imosk72🦄[GTGU] 9 Mar 2025 16:50
> The student’s home is located at the coordinates (1, 1), and the university is at the coordinates (N, M).
It means, for example, if N == 1 && M == 1 then university have same coordinates as home. Of course we can not use any roads in such case. But according to the sentence:
> There are a total of N streets running from north to south and M streets running from west to east.
there are some roads that can not be used. I think there should be N - 1 streets running from north to south and M - 1 streets running from west to east.