possible bug in checker for problem 060 Sweet Harvest

Back to Problem Solutions forum

Alexandr Milovantsev     2019-08-30 14:39:37

I encountered that my program finds solution with more optimal solutions then checer expected. For example for input string [10, 13, 11, 11, 2, 9, 6, 19, 6, 10, 18, 4, 15, 19, 18, 6, 19, 15, 13, 13, 4, 12] checker expect valuse 144, but my code finds solution 147 Rabbit visits isles on on positions with zero-based indices 1 3 5 7 10 12 14 16 19 21. This solution seems legitimate for me.

Alexandr Milovantsev     2019-08-30 15:00:07

Sorry, I was wrong, there is condition that rabbit starts from index=0, so index=1 is inaccessible for him. Сhanged code and passed check :)

Please login and solve 5 problems to be able to post at forum