Skip to content

Commit

Permalink
Issue 4164 - sieve Sample D Program -- need documentation for array …
Browse files Browse the repository at this point in the history
…representation
  • Loading branch information
Infiltrator committed Mar 19, 2014
1 parent 249a408 commit 24e526e
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions overview.dd
Expand Up @@ -1074,6 +1074,16 @@ int main()
----
)

$(P NB: The expectation may that array index x represents the number x. But it is not so.

At first glance the i + i + 3 seems very odd indeed.

However, if one were to consider each index, it would mean that the first element would represent 0 + 0 + 3 = 3;
the second element would represent 1 + 1 + 3 = 5;
the third element would represent 2 + 2 + 3 = 7;
and so on and so forth.

So the numbers represented by the array actually go from 3 to (8190 + 8190 + 3), or 16383.
)

This comment has been minimized.

Copy link
@CyberShadow

CyberShadow May 9, 2014

Member

The $(P block needs to be closed here. It also should have been added before the ) on line 1075, which is closing the section.


Macros:
Expand Down

0 comments on commit 24e526e

Please sign in to comment.