Skip to content
This repository has been archived by the owner on Oct 4, 2019. It is now read-only.

Commit

Permalink
Define division as floor divide
Browse files Browse the repository at this point in the history
  • Loading branch information
whilei committed Nov 16, 2017
1 parent ac3da5f commit 537451d
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion ECIPs/ECIP-1039.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,9 @@ The content of the proposal deals exclusively with reward calculation beginning

# Solution

### Definitions

- In this document, the mathematic and code symbol `/` should be understood as a "floor divide," and any fractions using `/` (_eg._ `1/32`) should _not_ be interpreted as floating points.

### __Block winner reward calculation.__

Expand Down Expand Up @@ -75,7 +78,7 @@ for (era in eras) {
_eg._
```
blockWinnerReward = blockWinnerRewardAtEra(n) # Block winner reward rounds down once prior to division
uncleInclusionReward = floor(1/32 * blockWinnerReward) # Block uncle inclusion reward rounds down per uncle
uncleInclusionReward = blockWinnerReward / 32 # Block uncle inclusion reward rounds down per uncle
```

And then either:
Expand Down

0 comments on commit 537451d

Please sign in to comment.