moakhey's blog

By moakhey, history, 9 years ago, In English

Hello, I've been trying to solve this problem on POJ: http://poj.org/problem?id=2084 After few drawings I understood that i should calculate the catalan number of the given n, however I got a WA. I think its because the size of the numbers which exceed the long long unsigned limit. What should I do? Am i wrong or should I operate on strings instead and perform my own multiplication?

  • Vote: I like it
  • +5
  • Vote: I do not like it

»
9 years ago, # |
  Vote: I like it 0 Vote: I do not like it

I remember that the catalan numbers did exceed long long limit, so it's a good idea to operate on big integers