zetaz's blog

By zetaz, history, 9 years ago, In English

Hello,

I had participated in a lot of online contest before.

I realised that I did better in long term contest (codechef long challenge, etc..) than short term contest (codeforces, topcoder).

But I'm afraid of what long term contest teach me:

  • I don't need to worry about time
  • I don't need to care about time management (Usually, I won't read other problem before I solve current problem)
  • I have a lot of time to optimise my solution
  • I have time to write brute-force solution and generator when I can't find mistake in my solution. (- debugging skill)

After doing many long term contest, I feel that long term contest also affect my performance in short term contest (including IOI/ACM ICPC), like being stuck on a problem (One of the reason I didn't get medal on IOI).

In fact, long term contest also affect me when training, I prefer to solve the problem by myself even when it took me a whole day because I feel that I have unlimited time.

What do you think ?

Learning from my mistake in IOI, I want to improve in short term contest. What do you think is a good training plan ? Do you think it is better to solve a problem by yourself after spending all day or try to think for like 30 minutes then read editorial ?

Full text and comments »

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

By zetaz, 11 years ago, In English

The Problem is :

Given N (1 <= N <= 10^6) numbers and K (1 <= K <= 23), each number can go up to 2^K-1. Now we can select some from the numbers to make a non empty set and OR all the number on the set, the problem ask the number of ways we can choose a set so the OR value will equal 2^K-1.

All i could think is O(N*(2^K)) Dynamic Programming which is too slow to solve this problem.

I'm sorry for my bad english. Does anyone have a better solution ?

Thanks

Full text and comments »

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