I am just a beginner trying to understand technical details of bitcoin. As far as I know, the Merkle root of a block works to provide summarizing hash of list of transactions. And according to my understanding, mining works by first hashing block header, appended with some bits and testing whether the resulting hash satisfies difficulty requirement.
My confusion is this: when hashing to perform mining, is Merkle root included? I am asking this as if Merkle root is included, then this would mean that mining depends on the transactions chosen to form a block. Thus it seems to me that if this is the case, then a miner can, by luck, choose some group of transactions that turns out to provide the hash that is under then target faster than other agents, assuming that other conditions are equal.