I think the only thing that's not trivial is the `A` block. The `D` blocks should just be changing `step(r)` to `diff(r)`