From 34b99da9cc497ba8d1d7fe2a8096952ab76fc6e5 Mon Sep 17 00:00:00 2001 From: "drusselloctal@gmail.com" Date: Thu, 30 Oct 2014 13:18:15 -0700 Subject: [PATCH] Made changes to ch05.asciidoc --- ch05.asciidoc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ch05.asciidoc b/ch05.asciidoc index 1caaf402..b4e7ac86 100644 --- a/ch05.asciidoc +++ b/ch05.asciidoc @@ -153,9 +153,9 @@ Transaction outputs associate a specific amount (in satoshis) to a specific _enc In simple terms, transaction inputs are pointers to UTXO. They point to a specific UTXO by reference to the transaction hash and sequence number where the UTXO is recorded in the blockchain. To spend UTXO, a transaction input also includes unlocking scripts that satisfy the spending conditions set by the UTXO. The unlocking script is usually a signature proving ownership of the bitcoin address that is in the locking script. -When a user makes a payment, their wallet constructs a transaction by selecting from the available UTXO. For example, to make a 0.015 bitcoin payment, the wallet app may select a 0.01 UTXO and a 0.005 UTXO, using them both to add up to the desired payment amount. +When users make a payment, their wallet constructs a transaction by selecting from the available UTXO. For example, to make a 0.015 bitcoin payment, the wallet app may select a 0.01 UTXO and a 0.005 UTXO, using them both to add up to the desired payment amount. -In the example below, we show the use of a "greedy" algorithm to select from available UTXO in order to make a specific payment amount. In the example, the available UTXO are provided as a constant array, but in reality, the available UTXO would be retrieved with an RPC call to Bitcoin Core, or to a third-party API as shown in <>. +In <>, we show the use of a "greedy" algorithm to select from available UTXO in order to make a specific payment amount. In the example, the available UTXO are provided as a constant array, but in reality, the available UTXO would be retrieved with an RPC call to Bitcoin Core, or to a third-party API as shown in <>. [[select_utxo]] .A script for calculating how much total bitcoin will be issued @@ -166,7 +166,7 @@ include::code/select-utxo.py[] ---- ==== -If we run the select-utxo.py script without a parameter it will attempt to construct a set of UTXO (and change) for a payment of 55000000 Satoshis (0.55 bitcoin). If you provide a target payment amount as a parameter, the script will select UTXO to make that target payment amount. Below, we run the script trying to make a payment of 0.5 bitcoin or 50000000 Satoshis: +If we run the _select-utxo.py_ script without a parameter, it will attempt to construct a set of UTXO (and change) for a payment of 55,000,000 satoshis (0.55 bitcoin). If you provide a target payment amount as a parameter, the script will select UTXO to make that target payment amount. In <>, we run the script trying to make a payment of 0.5 bitcoin or 50,000,000 satoshis. [[select_utxo_run]] .Running the select-utxo.py script