Square-and-multiply reads the exponent as a bit string. The anchor exponent is small enough to inspect row by row.

highlighted = computed this step

Write the exponent in bits

The exponent 13 is written as bits 1101.

13110113\to1101
Exponent bitsThe ladder rows are recomputed from pinned base, exponent, and modulus.Exponent bits - 7^13 mod 33stepbitpriorsquaremultiplyresult01117711716131320134skip4314161313

Read left to right

The square-and-multiply ladder reads those bits from left to right, so each row extends the value already built by earlier bits.

11011101
Exponent bitsThe ladder rows are recomputed from pinned base, exponent, and modulus.Exponent bits - 7^13 mod 33stepbitpriorsquaremultiplyresult01117711716131320134skip4314161313

See what the bits mean

Bits 1101 represent 8 plus 4 plus 1, which is exponent 13.

8+4+1=138+4+1=13
Exponent bitsThe ladder rows are recomputed from pinned base, exponent, and modulus.Exponent bits - 7^13 mod 33stepbitpriorsquaremultiplyresult01117711716131320134skip4314161313

One bit gives one row

There are 4 bits, so the ladder has 4 rows.

rows=4\text{rows}=4
Exponent bitsThe ladder rows are recomputed from pinned base, exponent, and modulus.Exponent bits - 7^13 mod 33stepbitpriorsquaremultiplyresult01117711716131320134skip4314161313

Zero still gets a row

The zero bit does not disappear. It still causes a square-and-reduce row; it only skips the multiply by the base.

zero bit means square only\text{zero bit means square only}
Exponent bitsThe ladder rows are recomputed from pinned base, exponent, and modulus.Exponent bits - 7^13 mod 33stepbitpriorsquaremultiplyresult01117711716131320134skip4314161313

Summary

The exponent controls the row sequence; the table exposes that control instead of hiding it inside a giant decimal power.

exponent bits drive the ladder\text{exponent bits drive the ladder}
Exponent bitsThe ladder rows are recomputed from pinned base, exponent, and modulus.Exponent bits - 7^13 mod 33stepbitpriorsquaremultiplyresult01117711716131320134skip4314161313