GNU Emacs Manual - RegNumbers

Go to the first, previous, next, last section, table of contents.

## Keeping Numbers in Registers

There are commands to store a number in a register, to insert the number in the buffer in decimal, and to increment it. These commands can be useful in keyboard macros (see section Keyboard Macros).

`C-u number C-x r n reg`
  Store number into register reg (`number-to-register`).
`C-u number C-x r + reg`
  Increment the number in register reg by number (`increment-register`).
`C-x r g reg`
  Insert the number from register reg into the buffer.

`C-x r g` is the same command used to insert any other sort of register contents into the buffer.

Go to the first, previous, next, last section, table of contents.