|
|
вернуться в форумIs there any trick? I'm using brute search with pruning, and all the cases which I tested seems alright, but I still get WA. Is there any trick? My code: [code deleted] Edited by moderator 28.07.2006 10:35 Brute force seems to be incorrect (+) Try this test: 8 4 5 6 5 4 5 6 5 The answer of your program is 34, while the correct answer is 33: 4 5 6 5 4 5 6 5 4 * * * 4 5 6 5 - 24 4 * * * * * * 5 - 9 * * * * * * * * My program uses BFS. Hope this will help. Good luck! Now it's AC Thanks for your test. I found my mistake, but it was very inefficient (4.11second). Do you know how some people solved it in less than 1 second? Re: Brute force seems to be incorrect (+) Are you sure that correct answer is 33? My program give answer 32 4 5 6 5 4 5 6 5 4 * * * 4 5 6 5 - 24 4 * * * 4 * * * - 8 * * * * * * * * But I have WA3 (. May be I don't understand this problem Re: Brute force seems to be incorrect (+) Your last step is incorrect. The balconies don't became circular after the shots. The distance between two final balconies is 4 in both directions, so the can't be destroyed by one shot. Re: Brute force seems to be incorrect (+) 4 5 6 5 4 5 6 5 4 * * * 4 5 6 5 - 24 4 * * * 4 * * * - 8 * * * * * * * * not like this? |
|
|