vamaddur's blog

By vamaddur, history, 7 years ago, In English

Problem Statement

Code

I tried using the logic in this blog post, but I keep getting WA. My code uses the identity 0*nC0+1*nC1+2*nC2+...+n*nCn = n*2^(n-1).

Can someone please find the flaw in my counting method (or even better, provide a test case that breaks my code)?

Thanks in advance!

  • Vote: I like it
  • 0
  • Vote: I do not like it

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

Auto comment: topic has been updated by vamaddur (previous revision, new revision, compare).

»
7 years ago, # |
  Vote: I like it +8 Vote: I do not like it

for ????0??? this case your code gives 448 and my Accepted code gives 928