def suffix
import bend-collections-laws-crypto@1.0.0.0/proofs/crypto/sha/packed/core_model.bend as CoreModelimport Base
198# SHA-256 round t (16 <= t < 64) with its constant as a literal. Like
199# window_rounds, q bounds the remaining rounds (48 for SHA-256) and each round
200# derives its schedule word from the rolling window before continuing with
201# round t+1. Defined last-to-first because names must precede use.
202def suffix(+n: Nat) -> List<&2, U32>:
203 128 <> List.append(&2, U32,
204 List.replicate(U32, Nat.mod(Nat.sub(119n, Nat.mod(n, 64n)), 64n), 0), bit_length(n))