How does Bitcoin Core Wallet calculate the weight of each input before it's spent?

The Bitcoin core wallet selection algorithms, particularly coin-grinder use a weight metric for each output. My understanding is that An output's weight is composed of the base_weight which is a constant amount plus a satisfaction_weight which is variable depending on the type of output and script/arguments needed to unlock it. My question is, how does bitcoin core know the weight during coin-selection before it's actually spent? Is this weight an estimate based on the type or is it accurately computed?



from Recent Questions - Bitcoin Stack Exchange https://ift.tt/1oKnNe3
via IFTTT

Popular posts from this blog

Do Kwon’s Detention Prolonged Until 2024 As Montenegro Responds To Extradition Requests

Sam Bankman-Fried Trial Begins Tomorrow: 3 Reasons Ex-SEC Official Foresees Conviction

April’s Crypto Game-Changers: 7 Events Set To Drastically Impact The Course Of Digital Currencies