## Keyboard shortcuts

Press `←` or `→` to navigate between chapters

Press `S` or `/` to search in the book

Press `?` to show this help

Press `Esc` to hide this help

- Auto
- Light
- Dark

# Algorand Specifications

An _entry_ is a pair e=(o,Q) where oo is some opaque object, and QQ is a 256-bit integer called a _seed_.

For a detailed definition of this object, see the [Algorand Ledger Specification](https://specs.algorand.co/ledger/ledger).

The following functions are defined on ee:

- _Encoding_: Encoding(e)=x where xx is a variable-length bitstring.

- _Summarizing_: Digest(e)=h where hh is a 256-bit integer. hh should be a cryptographic commitment to the contents of ee.

A _ledger_ is a sequence of entries L=(e1,e2,…,en).

A _round_ rr is some 64-bit index into this sequence.

The following functions are defined on LL:

- _Validating_: ValidEntry(L,o)=1 if and only if oo is _valid_ with respect to LL. This validity property is opaque.

- _Seed Lookup_: If er=(or,Qr), then Seed(L,r)=Qr.

- _Record Lookup_: Record(L,r,Ik)=(pkk,r,Bk,r,rfirst,rlast) for some address Ik, some public key pkk,r, and some 64-bit integer Bk,r. rfirst and rlast define the first valid and last valid rounds for this participating account.

- _Digest Lookup_: DigestLookup(L,r)=Digest(er).

- _Total Stake Lookup_: We use Krb,rv to represent all players with participation keys at r that are eligible to vote at rv. Let Krb,rv be the set of all kk for which (pkk,rb,Bk,rb,rfirst,rlast)=Record(L,rb,Ik) and rfirst≤rv≤rlast holds. Then Stake(L,rb,rv)=∑k∈Krb,rvBk,rb.

A ledger may support an opaque _entry generation_ procedure:

o:=Entry(L,Q)

which produces an object oo for which ValidEntry(L,o)=1.

> For implementation details on this procedure, see the _block assembly_ section in the [Algorand Ledger non-normative specification](https://specs.algorand.co/ledger/non-normative/ledger-nn-txpool-block-assembly).
