Spotify puzzle problem

后端 未结 2 1415
夕颜
夕颜 2021-01-13 11:17

I\'m trying to solve the \"best before\" Spotify puzzle described on this page. Basically, with an input of three integers separated by slashes (e.g. 11/3/4) you\'re suppose

2条回答
  •  不要未来只要你来
    2021-01-13 12:07

    There are problems in your 'year' handling. The puzzle text says

    Given a possibly ambiguous date "A/B/C", where A,B,C are integers between 0 and 2999, output the earliest possible legal date between Jan 1, 2000 and Dec 31, 2999 (inclusive) using them as day, month and year (but not necessarily in that order).

    However, when I enter years between 1000 and 2000 into your program, it will report them verbatim, even though they aren't valid output.

提交回复
热议问题