Order of transactions?
Is there a guarantee to the order in which transactions are applied/computed within a given block?
I believe that if a single Ethereum account transmits two transactions that are both mined into the same block, there is a defined order. The transaction with the lowest nonce would be applied first, right?
My main question is whether there is a similar guarantee if two different Ethereum accounts/users each transmit a transaction, and they interact with the same smart contract.
Say there's a jackpot contract that collects ether for a given amount of time, and then after a certain block height users can call claim() to withdraw the entire balance of the contract. The first user to call claim() gets the entire balance, and any subsequent calls will yield 0 ether. Alice and Bob each submit a call to claim(). Alice submits her transaction 5 seconds before Bob, and both transactions are mined into the same block.
Will Alice get the jackpot because her transaction was seen on the network first? Or is it basically random or up to the miner?
Submitted April 13, 2019 at 11:00AM }
via reddit http://bit.ly/2KBdgLZ