two block are broadcast almost at same time, which will be accepted? Because miners can choose which transaction will be added in block by themselves, so what if two miners broadcast two blocks almost at the same time, one is bigger(has more transactions), another is smaller. Which of the two blocks will be accepted?
Currently the Satoshi client will simply pick the one it sees first. Since most mining pools use the Satoshi client as their connection to the Bitcoin network they will build on top of the first block that is propagated to their node. The block that is propagated the furthest is therefore most likely to be the winner, i.e., the block that is part of the longest blockchain.

As you probably may have guessed there are also other strategies to pick the block to build on top. For example it might be the case that a block with more transactions offers more transaction fees to be claimed, hence a purely selfish miner may replace an earlier block with a new block that offers a higher reward. By that time however the miner has already spent some time trying to build a new block on top of the block with fewer fees, and it might have found a successor already.

So in the end, miners always work on the block they saw first (mining on top of an old block is rarely advantageous), and if they are selfish they may chose to replace their current base for a newer block if it offers more fees. Such a higher value block might however not be propagated to all miners, but that's another story.