shishir.hstu's blog

By shishir.hstu, history, 6 years ago, In English

I am getting WA this problem but could not find any critical case. Give some case. Thanks advance. . problem: https://uva.onlinejudge.org/external/125/12501.pdf my code: https://pastebin.com/Xk8mMJPr

  • Vote: I like it
  • -1
  • Vote: I do not like it

| Write comment?
»
6 years ago, # |
  Vote: I like it +6 Vote: I do not like it

Won't try to read your code as it is too long and messy. I will just give some general advice for debugging (as usual):

  1. Have you tried uDebug for test cases?
  2. Have you tried random test case + brute force answer generator?
  3. Have you tried extreme cases?
  4. Have you tried testing each of your methods in isolation?