Ok I got that part, both of them will get the payment,
BUT both of them are able to spend it too. REASON: I send the bitcoin to an address, has nothing to do with private key.
John Address is : AAAAA
Sarah Address is: AAAAA
so both open their wallets, they see 10 bitcoins I sent
Even if they have different private keys, since I sent it to an address and not a private key, then the transaction will show on both and both are able to spend it, just a matter of who spend it faster!
This part is correct.
Now John will spend 3 bitcoins.
Then it will show both of them have 7 Bitcoins left.
Then Sarah will spend 5 bitcoins.
Then it will show both of them have 2 bitcoin left.
Just a side note, when bitcoin are spent, you can't use a transaction output partially.
So, if John want to send CrapMan 3 BTC with a piece of "10 BTC" on his address, he need to create a transaction with that 10 btc as input, a output of "3 btc" to address 1 (controlled by CrapMan) and a output of "7 btc" to address 2 (controlled by John).
For most wallets software, by default, the wallet will generate a new change address every time to improve anonymity.
So, after John spend 3 btc, the common addresses held by John and Sarah will have nothing on it.
FYR:
https://en.bitcoin.it/wiki/ChangeOk you got me lost, you are way way smarter than me!
I sent John 10 BTC, John received them,
an output from my wallet was created, an input for John's wallet created.
John has now 10 BTC,
now John spent 3 BTC at amazon, an output of 3 BTC for John, an input of 3 BTC for Amazon
BUT I think you are saying my example of (John and Amazon) is wrong when you say partial output,
if I am not mistaken: you are saying that the whole BTCs in the wallet create an output even if you spend only part of them? like when John spent 3 BTC on Amazon from that 10 BTC, it means: an output of 3 BTC created to amazong and another output for 7 BTC created to John (output of his own money to his own wallet)?