Bitcoin Forum
April 30, 2024, 11:14:07 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: And the next code line is: ?  (Read 1124 times)
remotemass (OP)
Legendary
*
Offline Offline

Activity: 1116
Merit: 1016


ASMR El Salvador


View Profile WWW
September 13, 2013, 01:57:36 PM
Last edit: September 13, 2013, 03:24:01 PM by remotemass
 #1

I am starting this thread for us to keep active with an ongoing challenge, to comment one of the 12,222 lines of code in the original version of Satoshi's bitcoin client code (bitcoin-0.1.0), namely the line numbered with: ('next block hash in decimal' mod '12222').
Please commit to comment about it only during the time within blocks creation so that when a new block is created we move on to discuss about the next line we are faced with. This will prevent the discussion in this thread to become too much of a mess and keep us focused on the here and now of the code line we are faced with.
If some of us could please help others keeping this thread updated in terms of telling simply what is the next code line we got so that others can focus entirely on commenting about it, it could make our lives easier.
Please contextualize your code comments of the new line of code being analysed and discussed as much as possible so that this thread can become an interestingly active and valuable resource.
I fear this thread may not gain traction, but let's see. I will try to do my part contributing a bit to it now and then.
I think we shoud start with the 12,222 lines of code of the original client (http://pastebin.com/MfABqyJd) and maybe later consider other versions, with other threads, perhaps.
Again, let's try to focus on the code line drawing we are on right at this moment, and try to let go of what was missed in the previous ones.
This little rule is just a guideline and you may override it if you think it makes sense, of course.
Will you help?

Inventor of: "Conic-Upward-Jet-Thrust 𝕊ℙ𝔸ℂ𝔼 𝔼𝕃𝔼𝕍𝔸𝕋𝕆ℝ" ¦¦ Monetize pics of in/out cash (with GPS metatag on and timestamp captions) ¦¦ Forking LITECOIN: bitcointalk.org/index.php?topic=5362345
1714475647
Hero Member
*
Offline Offline

Posts: 1714475647

View Profile Personal Message (Offline)

Ignore
1714475647
Reply with quote  #2

1714475647
Report to moderator
1714475647
Hero Member
*
Offline Offline

Posts: 1714475647

View Profile Personal Message (Offline)

Ignore
1714475647
Reply with quote  #2

1714475647
Report to moderator
1714475647
Hero Member
*
Offline Offline

Posts: 1714475647

View Profile Personal Message (Offline)

Ignore
1714475647
Reply with quote  #2

1714475647
Report to moderator
In order to get the maximum amount of activity points possible, you just need to post once per day on average. Skipping days is OK as long as you maintain the average.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
remotemass (OP)
Legendary
*
Offline Offline

Activity: 1116
Merit: 1016


ASMR El Salvador


View Profile WWW
September 13, 2013, 02:24:34 PM
 #2

http://www.stringfunction.com/hex-decimal.html
http://www.calculatorpro.com/calculator/modulo-calculator/

Block #257748 hash in decimal: 227538544328062966004888208644466284604660868282826408848828

227538544328062966004888208644466284604660868282826408848828 mod 12222 = 196

Line 196 is:         BN_clear_free(this);


Can you comment a bit on this line of code, please?

Inventor of: "Conic-Upward-Jet-Thrust 𝕊ℙ𝔸ℂ𝔼 𝔼𝕃𝔼𝕍𝔸𝕋𝕆ℝ" ¦¦ Monetize pics of in/out cash (with GPS metatag on and timestamp captions) ¦¦ Forking LITECOIN: bitcointalk.org/index.php?topic=5362345
joshlang
Newbie
*
Offline Offline

Activity: 26
Merit: 0


View Profile
September 13, 2013, 02:51:45 PM
 #3

http://www.stringfunction.com/hex-decimal.html
http://www.calculatorpro.com/calculator/modulo-calculator/

Block #257748 hash in decimal: 227538544328062966004888208644466284604660868282826408848828

227538544328062966004888208644466284604660868282826408848828 mod 12222 = 196

Line 196 is:         BN_clear_free(this);


Can you comment a bit on this line of code, please?

BN_clear_free(this);   // sets the memory for the bignumber to all zeroes and frees the memory, thereby saving many trees and dolphins in the process.
chriswilmer
Legendary
*
Offline Offline

Activity: 1008
Merit: 1000


View Profile WWW
September 13, 2013, 03:18:40 PM
 #4

this is a great idea! watching this thread
remotemass (OP)
Legendary
*
Offline Offline

Activity: 1116
Merit: 1016


ASMR El Salvador


View Profile WWW
September 13, 2013, 03:31:41 PM
 #5

Block #257757 hash in decimal:

115419387065509120046808062824008482828448080082064264248062

115419387065509120046808062824008482828448080082064264248062 mod 12222 = 7730

Line 7730 is:     {

Can you contextualize it a bit, please?

Inventor of: "Conic-Upward-Jet-Thrust 𝕊ℙ𝔸ℂ𝔼 𝔼𝕃𝔼𝕍𝔸𝕋𝕆ℝ" ¦¦ Monetize pics of in/out cash (with GPS metatag on and timestamp captions) ¦¦ Forking LITECOIN: bitcointalk.org/index.php?topic=5362345
remotemass (OP)
Legendary
*
Offline Offline

Activity: 1116
Merit: 1016


ASMR El Salvador


View Profile WWW
September 13, 2013, 03:47:08 PM
 #6

Block #257761 => Line 7916

template<typename K, typename T>

Inventor of: "Conic-Upward-Jet-Thrust 𝕊ℙ𝔸ℂ𝔼 𝔼𝕃𝔼𝕍𝔸𝕋𝕆ℝ" ¦¦ Monetize pics of in/out cash (with GPS metatag on and timestamp captions) ¦¦ Forking LITECOIN: bitcointalk.org/index.php?topic=5362345
remotemass (OP)
Legendary
*
Offline Offline

Activity: 1116
Merit: 1016


ASMR El Salvador


View Profile WWW
September 13, 2013, 05:05:40 PM
 #7

Block #257771 => Line 9436

nPrice = nPriceIn;

Inventor of: "Conic-Upward-Jet-Thrust 𝕊ℙ𝔸ℂ𝔼 𝔼𝕃𝔼𝕍𝔸𝕋𝕆ℝ" ¦¦ Monetize pics of in/out cash (with GPS metatag on and timestamp captions) ¦¦ Forking LITECOIN: bitcointalk.org/index.php?topic=5362345
grue
Legendary
*
Offline Offline

Activity: 2058
Merit: 1431



View Profile
September 13, 2013, 05:26:54 PM
 #8

this is a pointless thread, reminiscent of the "count to 2100000 with pictures" thread. no sane software developer will comment every single line. tell me, what is the purpose of posts like these?
BN_clear_free(this);   // sets the memory for the bignumber to all zeroes and frees the memory, thereby saving many trees and dolphins in the process.
Block #257771 => Line 9436

nPrice = nPriceIn;
Block #257761 => Line 7916

template<typename K, typename T>
anyone anyone who took a high school course in programming will know what they mean.

if you want to comment every line, fine. do it on the source file themselves and upload it to a github repo or your own site. don't spam the forums in a vain attempt to boost your post count.

It is pitch black. You are likely to be eaten by a grue.

Adblock for annoying signature ads | Enhanced Merit UI
remotemass (OP)
Legendary
*
Offline Offline

Activity: 1116
Merit: 1016


ASMR El Salvador


View Profile WWW
September 13, 2013, 05:46:17 PM
 #9

I suppose you say the same thing about Sanskrit sutras.  Angry
Your attitude is arrogant and offensive, although I don't want to take it personally.
I really don't think you are the master of the universe and know what is the best for everybody in the community. Besides, there are not just developers in this community, in case you don't know.

Inventor of: "Conic-Upward-Jet-Thrust 𝕊ℙ𝔸ℂ𝔼 𝔼𝕃𝔼𝕍𝔸𝕋𝕆ℝ" ¦¦ Monetize pics of in/out cash (with GPS metatag on and timestamp captions) ¦¦ Forking LITECOIN: bitcointalk.org/index.php?topic=5362345
grue
Legendary
*
Offline Offline

Activity: 2058
Merit: 1431



View Profile
September 13, 2013, 06:55:32 PM
Last edit: September 13, 2013, 07:16:59 PM by grue
 #10

I suppose you say the same thing about Sanskrit sutras.  Angry
this is a forum, not a religious scripture

Your attitude is arrogant and offensive, although I don't want to take it personally.
please get a better argument rather than appealing to tone

I really don't think you are the master of the universe and know what is the best for everybody in the community. Besides, there are not just developers in this community, in case you don't know.
I never claimed I was "the master of the universe and know what is the best for everybody in the community". Instead of strawmaning, how about you actually refute some of my arguments?

It is pitch black. You are likely to be eaten by a grue.

Adblock for annoying signature ads | Enhanced Merit UI
remotemass (OP)
Legendary
*
Offline Offline

Activity: 1116
Merit: 1016


ASMR El Salvador


View Profile WWW
September 13, 2013, 07:28:43 PM
 #11

I never claimed I was "the master of the universe and know what is the best for everybody in the community". Instead of strawmaning, how about you actually refute some of my arguments?

In the same way that whole books can be written about a single sutra in a religious scripture, many things can certainly be said about a single line of code. I find it unbelivable that you really think that "everybody will know what this means" is really the best thing that can be said to shed some light on such a dense and difficult to understand code program.

What I mean is that your attitude of "I am a staff Member and can kick you out of this forum if I want" is really not what is expected from a leading position of a community with such a free and open spirit.
I really don't like this kind of suppressive attittude and expected more from a staff member of this forum. Would it bother you that much that this became a popular thread? Why? Are you against the joy, fun and engaging of others? I wonder.

Don't you see this would indeed be interesting for people that want to have a better appreciation of the bitcoin client code and are finding it really difficult to harvest light out of the darkness?

It's really narrow-minded to think nothing of relevant can be said. Of course, you may say: "there's nothing to be said about this". "Everyone that can read code will get it".
Sure... NOT!

Inventor of: "Conic-Upward-Jet-Thrust 𝕊ℙ𝔸ℂ𝔼 𝔼𝕃𝔼𝕍𝔸𝕋𝕆ℝ" ¦¦ Monetize pics of in/out cash (with GPS metatag on and timestamp captions) ¦¦ Forking LITECOIN: bitcointalk.org/index.php?topic=5362345
deepceleron
Legendary
*
Offline Offline

Activity: 1512
Merit: 1028



View Profile WWW
September 14, 2013, 12:13:09 AM
 #12

Original Bitcoin code is decently commented compared with many commits these days. What is missing is a script and protocol overview and design document.
remotemass (OP)
Legendary
*
Offline Offline

Activity: 1116
Merit: 1016


ASMR El Salvador


View Profile WWW
September 18, 2013, 06:32:13 PM
 #13

O GRITO DO TANGO

Inventor of: "Conic-Upward-Jet-Thrust 𝕊ℙ𝔸ℂ𝔼 𝔼𝕃𝔼𝕍𝔸𝕋𝕆ℝ" ¦¦ Monetize pics of in/out cash (with GPS metatag on and timestamp captions) ¦¦ Forking LITECOIN: bitcointalk.org/index.php?topic=5362345
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!