|
|
вернуться в форумCan't resolve problem on ruby, Time Exceed Issue Hello, I've implemented two solutions: DP and Brut Force on ruby, but still no luck to pass tests (#3, #4). Does someone have good solution on ruby for that problem? Is it my bad hands, or tests were changed and ruby cant process it fast. If you have accepted solution, please try to submit it again. Also, if you resolved it on ruby, please give some specific hints about solution. Thanks! Re: Can't resolve problem on ruby, Time Exceed Issue I don't know much about Ruby but I've solved this problem on Python which I suppose has similar performance. It's very important to optimize algorithm very well in order to pass all tests on those script languages. Time your code and try not to exceed 1 sec. limit with 20 stones. Sorry, no hints about algorithm from me. |
|
|